2005年7月24日19:13星期日
我的ubuntu默認Runlevel rc2 的服務(wù)簡(jiǎn)析 代碼:
yongyi@yongyi:~$ cd /etc/rc2.d/
yongyi@yongyi:/etc/rc2.d$ ls -al
總用量 16
drwxr-xr-x 2 root root 4096 2005-07-22 19:17 .
drwxr-xr-x 102 root root 8192 2005-07-24 16:42 ..
lrwxrwxrwx 1 root root 17 2005-07-22 19:13 K11anacron -> ../init.d/
anacron #anacron 是和 cron 相似的任務(wù)調度器,只不過(guò)它并不要求系統持續運行。它可以用來(lái)運行通常由 cron 運行的每日、每周、和每月的作業(yè)。
lrwxrwxrwx 1 root root 17 2005-07-22 19:13 S05vbesave -> ../init.d/
vbesave lrwxrwxrwx 1 root root 18 2005-07-23 02:56 S10sysklogd -> ../init.d/
sysklogd #sysklogd 就是syslog,是操作系統提供的一種機制,守護程序通常使用這種機制將各種信息寫(xiě)到各個(gè)系統日志文件。通常應該啟動(dòng)該服務(wù)。
lrwxrwxrwx 1 root root 15 2005-07-23 02:56 S11klogd -> ../init.d/
klogd #klogd 是系統日志守候進(jìn)程
lrwxrwxrwx 1 root root 14 2005-07-23 02:56 S12alsa -> ../init.d/
alsa #alsa 是Alsa聲卡驅動(dòng)程序支持
lrwxrwxrwx 1 root root 13 2005-07-22 19:17 S13gdm -> ../init.d/
gdm #gdm 是窗口管理器的一種
lrwxrwxrwx 1 root root 13 2005-07-23 02:56 S14ppp -> ../init.d/
ppp #ppp 服務(wù),用于撥號上網(wǎng)。它客戶(hù)端程序有chat和pppd。還有一個(gè)終端通信程序minicom,用來(lái)測試撥號用的,也要安裝上。chat程序的用途是撥號,并等待提示,根據提示輸入用戶(hù)名和密碼等登錄信息。pppd的用途是建立并維持與服務(wù)器的PPP連接,并傳輸數據。
lrwxrwxrwx 1 root root 16 2005-07-22 19:15 S19cupsys -> ../init.d/
cupsys #cupsys 是cups服務(wù)cupsys,用于本地或遠程打印
lrwxrwxrwx 1 root root 15 2005-07-22 19:13 S20acpid -> ../init.d/
acpid #acpid 是Advanced Configuration and Power Interface,為替代傳統的APM電源管理標準而推出的新型電源管理標準。配置文件:/proc/acpi/event
lrwxrwxrwx 1 root root 14 2005-07-22 19:13 S20apmd -> ../init.d/
apmd #apmd 用來(lái)監視系統用電狀態(tài),并將相關(guān)信息通過(guò)syslogd 寫(xiě)入日志。也可以用來(lái)在電源不足時(shí)關(guān)機。如果我們使用的是臺式電腦或一直開(kāi)機的機型,就不需要使用這個(gè)守護程序。配置文件:/etc/sysconfig/apmd
lrwxrwxrwx 1 root root 16 2005-07-22 19:13 S20dbus-1 -> ../init.d/
dbus-1 #dbus-1 是自動(dòng)掛載服務(wù)吧,用于顯示 /etc/fstab 內指定到 /media/ 的掛載。hotplug模塊自動(dòng)加載工具和它以及gnome-volume-manager配合使用,可以象win2000那樣幫你自動(dòng)mount文件系統。
lrwxrwxrwx 1 root root 15 2005-07-23 02:55 S20inetd -> ../init.d/
inetd #inetd 是因特網(wǎng)操作服務(wù)程序。監控網(wǎng)絡(luò )對各種它管理的服務(wù)的需 求,并在必要的時(shí)候啟動(dòng)相應的服務(wù)程序。通常,inetd 管理的程序有telnet、ftp、rsh和rlogin。 關(guān)閉inetd也就 關(guān)閉了這些由它管理的服務(wù)。
lrwxrwxrwx 1 root root 17 2005-07-23 02:54 S20makedev -> ../init.d/
makedev #makedev 是在/dev目錄下創(chuàng )建設備文件的程序。/etc/devinfo 用來(lái)給makedev這個(gè)程序設定各種不同的設備驅動(dòng)文件的格式.用戶(hù)不用設置。
lrwxrwxrwx 1 root root 17 2005-07-23 02:56 S20postfix -> ../init.d/
postfix #postfix 是為用戶(hù)提供除sendmail之外的郵件服務(wù)器選擇。postfix沒(méi)有提供pop3,但可擴展性、編程接口比較好。配置文件位于/etc/postfix目錄下,一共有四個(gè)最基本的配置文件:install.cf main.cf master.cf postfix-script。
lrwxrwxrwx 1 root root 19 2005-07-22 19:14 S20powernowd -> ../init.d/
powernowd #powernowd 用于自動(dòng)調整你的 CPU 頻率
lrwxrwxrwx 1 root root 15 2005-07-23 02:55 S20rsync -> ../init.d/
rsync #rsync 是remote sync,遠程數據備份工具。
lrwxrwxrwx 1 root root 15 2005-07-23 02:55 S25mdadm -> ../init.d/
mdadm #mdadm 用于創(chuàng )建和管理RAID陣列,配置文件是/etc/mdadm.conf
lrwxrwxrwx 1 root root 17 2005-07-22 19:13 S89anacron -> ../init.d/
anacron #anacron 是一個(gè)自動(dòng)化運行任務(wù)工具。配置文件:/etc/anacron
lrwxrwxrwx 1 root root 13 2005-07-23 02:56 S89atd -> ../init.d/
atd #atd 是一個(gè)自動(dòng)化運行任務(wù)。通常需要啟動(dòng)。不過(guò)如果你一直使用cron,那么也可以不啟動(dòng)。配置文件:/etc/at.allow,/etc/at.deny
lrwxrwxrwx 1 root root 14 2005-07-23 02:55 S89cron -> ../init.d/
cron #cron 是用來(lái)執行例行性命令的守護程序。必須啟動(dòng)。配置文件:/etc/crontab
lrwxrwxrwx 1 root root 22 2005-07-22 19:13 S99acpi-support -> ../init.d/
acpi-support #acpi-support 相信是提供高級電源管理的。
lrwxrwxrwx 1 root root 19 2005-07-22 19:13 S99fetchmail -> ../init.d/
fetchmail #fetchmail 是一個(gè)和電子郵件相關(guān)的好用工具,被應用在臨時(shí)接通的 TCP/IP 線(xiàn)路 (例如 SLIP 或 PPP 連線(xiàn))上, 用來(lái)讀取遠程信件及轉遞信件,可以支持 IPv6 和 IPSEC (即 IP 安全協(xié)議)
lrwxrwxrwx 1 root root 19 2005-07-23 02:54 S99rmnologin -> ../init.d/
rmnologin #rmnologin 是必需的,man nologin有這樣描述:nologin - prevent non-root users from logging into the system
lrwxrwxrwx 1 root root 23 2005-07-23 02:54 S99stop-bootlogd -> ../init.d/
stop-bootlogd #stop-bootlogd 是用來(lái)停止bootlogd 模塊的,bootlogd 記錄所有發(fā)送到終端的字符串
Edit at 2005-09-11 今天看了看breezy下的服務(wù),并關(guān)掉了一部分對我沒(méi)什么用的(為了方便知道它的順序,所以只是改變前面的字母):
root@ubuntu:/etc/rc2.d # ls
K01fetchmail S12dbus S20apmd S20samba S99rmnologin
S05vbesave S13gdm S20hotkey-setup S25bluez-utils S99stop-bootlogd
S10acpid S14ppp S20makedev S25mdadm
S10sysklogd S19cupsys S20pcmcia S89anacron
S11klogd S19hplip S20powernowd S99acpi-support
root@ubuntu:/etc/rc2.d # mv K01fetchmail k01fetchmail
root@ubuntu:/etc/rc2.d # mv S10acpid s10acpid
root@ubuntu:/etc/rc2.d # mv S14ppp s14ppp
root@ubuntu:/etc/rc2.d # mv S19cupsys s19cupsys
root@ubuntu:/etc/rc2.d # mv S19hplip s19hplip
root@ubuntu:/etc/rc2.d # mv S20apmd s20apmd
root@ubuntu:/etc/rc2.d # mv S20pcmcia s20pcmcia
root@ubuntu:/etc/rc2.d # mv S25mdadm s25mdadm
root@ubuntu:/etc/rc2.d # mv S99acpi-support sacpi-support
root@ubuntu:/etc/rc2.d # mv S25bluez-utils s25bluez-utils
解釋兩個(gè):
hotkey-setup:
auto-configures laptop hotkeys
This package will attempt to auto-detect your laptop hardware and then configure its hotkeys to produce useful keycodes. These can then be used by userspace applications.
bluez-utils:
bluez-utils 是 Linux 上一套在 BlueZ 實(shí)作的 Bluetooth 無(wú)線(xiàn)網(wǎng)路標準上使用的 工具。
yongyi@ubuntu:~$ sudo chmod -x /etc/init.d/ntpdate
yongyi@ubuntu:/etc/rc6.d$ ls
K01gdm K20acpi-support K25hwclock.sh K89hotplug-net S36ifupdown
K11anacron K20apmd K25mdadm K89klogd S40umountfs
K12dbus K20hotkey-setup K50alsa-utils K90sysklogd S50lvm
K15fetchmail K20makedev K74bluez-utils S20sendsigs S50mdadm-raid
K19cupsys K20pcmcia K75hdparm S30urandom S90reboot
K19hplip K20powernowd K76readahead S31umountnfs.sh
K19samba K21acpid K86ppp S35networking
yongyi@ubuntu:/etc/rc6.d$ sudo mv K15fetchmail k15fetchmail
yongyi@ubuntu:/etc/rc6.d$ sudo mv K19cupsys k19cupsys
yongyi@ubuntu:/etc/rc6.d$ sudo mv K19hplip k19hplip
yongyi@ubuntu:/etc/rc6.d$ sudo mv K20acpi-support k20acpi-support
yongyi@ubuntu:/etc/rc6.d$ sudo mv K20apmd k20apmd
yongyi@ubuntu:/etc/rc6.d$ sudo mv K20pcmcia k20pcmcia
yongyi@ubuntu:/etc/rc6.d$ sudo mv K21acpid k21acpid
yongyi@ubuntu:/etc/rc6.d$ sudo mv K25mdadm k25mdadm
yongyi@ubuntu:/etc/rc6.d$ sudo mv K74bluez-utils k74bluez-utils
yongyi@ubuntu:/etc/rc6.d$ sudo mv K86ppp k86ppp
Ubuntu Start-up http://joe.terrarum.net/geek/linux/ubuntu-startup.html (Intro)
This will describe and explain the start-up process of Ubuntu Linux.
(rc2.d)
Like Debian, Ubuntu boots up in runlevel 2. Because of that, we'll find the details we want in /etc/rc2.d. Inside that directory, we find:
>> sysklogd
>> klogd
>> ppp
>> portmap
>> acpid
>> alsa
>> apmd
>> autofs
>> cupsys
>> dbus-1
>> fam
>> inetd
>> makedev
>> postfix
>> powernowd
>> rsync
>> mdadm
>> atd
>> cron
>> acpi-support
>> fetchmail
>> gdm
>> rmnologin
>> stop-bootlogd
(start-stop-daemon)
An important utility to understand first is the Debian utility, start-stop-daemon. It's a simple program that manages starting and stopping running daemons. Each program under /etc/rc2.d utilizes this program to manage their process.
(init-functions)
All services run /lib/lsb/init-functions. This file contains helper functions for the start-stop-daemon program. It helps manage the pid files under /var/run and provides the text-output and logging when the status of a service changes.
(sysklogd)
Sysklogd is the system log daemon. As the description implies, it allows the system to log messages. Options may be specified in the SYSKLOGD variable. The daemon then starts and reads its configuration from /etc/syslog.conf. More information can be found here
(klogd)
Klogd provides kernel logging. Klogd will obtain kernel messages from /proc/kmsg, but if /proc doesn't exist, it will use the system call interface. All kernel messages are routed through syslog which then places them in the /var/log/kern.log file.
(ppp)
This file checks if /etc/ppp/ppp_on_boot exists and if it does, connect to the users ISP.
(portmap)
Portmap converts RPC calls into standard DARPA (tcp/ip) port numbers. This file reads /etc/default/portmap which tells portmap to only run on the local loopback interface.
(acpid)
acpid is a power management daemon. It will sit and read /proc/acpi/event until it receives a whole line. Once then, it checks /etc/acpi/events for a qualifying action for that event. By default, Ubuntu loads the following acpi related modules: battery, ac, processor, button, fan, and thermal. More info can be found here
(alsa)
Alsa is the Advanced Linux Sound Architecture. It reads in some basic settings from /etc/default/alsa then loads up the stored alsa settings. More info can be found here
(apmd)
apmd is another power management daemon. This one really just cares about battery power, system standby, system suspend, and system resume. More info can be found here
(autofs)
autofs controls the automount daemon. autofs reads /etc/auto.master for various mount points of mounting drives.
(cups)
cups is the Common Unix Printing System. It provides and extremely easy system for configuring a printer under linux. More info can be found here
(dbus-1)
dbus is a system for providing Inter Process Communications between two applications. As freedesktop explains, examples of this include a camera being plugged in or file monitoring. More info can be found here
(famd)
famd is the File Alteration Monitor daemon. It provides a system that applications can use to detect when a file changes.
(inetd)
inetd provides a list of services and ports they run on under /etc/inetd.conf. It then listens for requests for those ports, and once received, runs that service.
(makedev)
makedev simply re-creates a symlink from /sbin/MAKEDEV to /dev/MAKEDEV
(postfix)
Postfix is a Mail Transport Agent or MTA. This provides local system mail transportation, and if configured correctly, internet-wide mail transportation. More info can be found here
(powernowd)
powernowd is a client for cpufreq which, as the name implies, controls the CPU frequency. By using this, you may raise the frequency of your cpu when your computer may need the extra power and lower it during idle time. This is especially useful for laptops when heat is concerned.
(rsync)
This would start the rsync daemon on your system but, by default, it is disabled.
(mdadm)
mdadm manages software RAID under linux. More info can be found here
(atd)
atd is the at daemon and manages processes scheduled to run at later times.
(crond)
crond is the cron daemon and manages processes that may be on a repetitive schedule.
(acpi-support)
This is just a helper script for the acpi daemon. Depending on what mode a laptop is in (battery or AC), it will set the systems power accordingly.
(fetchmail)
fetchmail manages retrieving email. This script checks for /etc/fetcmailrc and if it doesnt exist (it doesnt by default), then it does not start. More info can be found here
(gdm)
gdm is the GNOME Display Manager. It starts X Windows and provides a graphical login screen. More info can be found here
(rmnologin)
This script removes the /etc/rmnologin file. rmnologin prevents non-root users from logging in.
(stop-bootlogd)
Just like the name implies, this stops the bootlogd daemon. bootlogd logs all strings sent to the console.
Linux系統各項服務(wù) 1、alsasound
Alsa聲卡驅動(dòng)程序支持。Alsa聲卡驅動(dòng)程序本來(lái)是為了一種聲卡Gravis UltraSound(GUS)而寫(xiě)的,該程序被證 明很優(yōu)秀,于是作者就開(kāi)始為一般的聲卡寫(xiě)驅動(dòng)程序。Alsa和OSS/Free 及OSS/Linux兼容,但是有自己的接口,甚至比OSS優(yōu)秀。
2、amd
運行automount精靈程序,該精靈在必要時(shí)自動(dòng)安裝一些本地設備和NFS文件系統。
3、apmd
apmd用來(lái)監視系統用電狀態(tài),并將相關(guān)信息通過(guò)syslogd 寫(xiě)入日志。也可以用來(lái)在電源不足時(shí)關(guān)機。
4、arpwatch
該程序主要用來(lái)維護以太網(wǎng)物理地址和IP地址的對應關(guān)系。
5、atalk
AppleTalk精靈程序。注意不要在后臺運行該程序,該程序的數據結構必須在運行其他進(jìn)程前先花一定時(shí)間初始化。
6、atd
運行用戶(hù)用At命令調度的任務(wù)。也在系統負荷比較低時(shí)運行批處理任務(wù)。
7、autofs
當您需要時(shí)自動(dòng)轉載文件系統,而當您不需要時(shí)自動(dòng)卸載。
8、bootparamd
該服務(wù)允許老的Sun工作站從Linux網(wǎng)絡(luò )啟動(dòng),它和rarp現在很少使用,基本上被bootp和dhcp取代了。
9、crond
cron是Unix下的一個(gè)傳統程序,該程序周期地運行用戶(hù)調度的任務(wù)。比起傳統的Unix版本,Vixie版本添加了不少屬性,而且更安全,配置更簡(jiǎn)單。
10、dhcpd
該精靈提供了對動(dòng)態(tài)主機控制協(xié)議(Dynamic Host Control Protocol)的訪(fǎng)問(wèn)支持。
11、gated
gated通過(guò)一個(gè)數據庫提供了網(wǎng)絡(luò )路由功能支持。它支持各種路由協(xié)議,包括RIP版本1和2、DCN HELLO協(xié)議、OSPF版本2以及EGP版本2到4。
12、gpm
gpm為文本模式下的Linux程序如mc(Midnight Commander)提供了鼠標的支持。它也支持控制臺下鼠標的拷貝,粘貼操作以及彈出式菜單。
13、httpd
http是著(zhù)名的www服務(wù)器,可用來(lái)提供HTML文件以及CGI動(dòng)態(tài)內容服務(wù)。
14、inetd
因特網(wǎng)操作服務(wù)程序。監控網(wǎng)絡(luò )對各種它管理的服務(wù)的需求,并在必要的時(shí)候啟動(dòng)相應的服務(wù)程序。通常,inetd管理的程序有telnet、ftp、rsh和rlogin。關(guān)閉inetd也就關(guān)閉了這些由它管理的服務(wù)。
15、innd
inn是最流行的用戶(hù)組新聞服務(wù)器。它允許您建立起本地新聞服務(wù)器。配置有一定的難度,可以先閱讀/usr/doc/ inn*文檔獲得幫助。
16、keytable 該程序的功能是轉載您在/etc/sysconfig/keyboards里說(shuō) 明的鍵盤(pán)映射表,該表可以通過(guò)kbdconfig工具進(jìn)行選 擇。您應該使該程序處于激活狀態(tài)。
17、ldap
LDAP代表Lightweight Directory Access Protocol,實(shí)現了目錄訪(fǎng)問(wèn)協(xié)議的行業(yè)標準。
18、linuxconf
linuxconf是Linux下的一個(gè)有效的系統配置工具,該服務(wù)允許遠程運行。
19、lpd
lpd是系統打印守護程序,負責將lpr等程序提交給打印作業(yè)。
20、mcserv
Midnight Commander服務(wù)進(jìn)程允許遠程機器上的用戶(hù)通過(guò)Midnight Commander文件管理器操作本機文件。服務(wù)進(jìn)程用PAM來(lái)驗證用戶(hù),需要給出“用戶(hù)名/口令”以通過(guò)驗證。
21、mysql
一個(gè)快速高效可靠的輕型SQL數據庫引擎。
22、named
域名服務(wù)器,將Internet主機名解析為點(diǎn)分的IP地址。
23、netfs
負責裝載/卸載NFS、Samba、NCP(Netware)文件系統。
24、network 激活/關(guān)閉啟動(dòng)時(shí)的各個(gè)網(wǎng)絡(luò )接口。
25、nfs
NFS是一個(gè)流行的基于TCP/IP網(wǎng)絡(luò )的文件共享協(xié)議。該服務(wù)提供了NFS文件共享服務(wù),具體的配置在/etc/ exports文件里。
26、nscd
該服務(wù)負責密碼和組的查詢(xún),并且緩沖查詢(xún)結果。如果您的系統有比較慢的服務(wù)(如NIS和NIS+),則應該啟動(dòng)該服務(wù)。
27、pcmcia
pcmcia主要用于支持筆記本電腦。
28、portmap
portmap用來(lái)支持RPC連接,RPC被用于NFS以及NIS等服務(wù)。
29、postgresql
PostgreSQL關(guān)系數據庫引擎。
30、proftpd
proftpd是Unix下的一個(gè)配置靈活的ftp守護程序。
31、radvd
路由廣播程序。
32、random
保存和恢復系統的高質(zhì)量隨機數生成器,這些隨機數是系統一些隨機行為提供的。
33、routed
該守護程序支持RIP協(xié)議的自動(dòng)IP路由表維護。RIP主要使用在小型網(wǎng)絡(luò )上,大一點(diǎn)的網(wǎng)絡(luò )就需要復雜一點(diǎn)的協(xié)議。
34、rstatd
Rstat協(xié)議允許網(wǎng)絡(luò )上的用戶(hù)獲得同一網(wǎng)絡(luò )上各機器的性能參數。
35、rusersd
該服務(wù)使網(wǎng)絡(luò )用戶(hù)可以定位同一網(wǎng)絡(luò )上的其他用戶(hù)。
36、rwalld
Rwall協(xié)議允許遠程用戶(hù)向在同一系統中活躍著(zhù)的終端發(fā)送消息,類(lèi)似wall的本地行為。
37、rwhod
允許遠程用戶(hù)獲得運行rwho精靈的機器上所有已登錄用戶(hù)的列表,與finger類(lèi)似。
38、sendmail
大名鼎鼎的郵件服務(wù)器。
39、smb
啟動(dòng)和關(guān)閉smbd和nmbd精靈程序以提供SMB網(wǎng)絡(luò )服務(wù)。
40、snmpd
簡(jiǎn)單網(wǎng)絡(luò )管理協(xié)議(SNMP)的守護精靈。
41、syslog
syslog是操作系統提供的一種機制,守護程序通常使用這種機制將各種信息寫(xiě)到各個(gè)系統日志文件。通常應該啟動(dòng)該服務(wù)。
42、xfs
X的字體服務(wù)器。
43、ypbind
NIS/YP的客戶(hù)端守護程序。如果您需要使用NIS/YP機器,請啟動(dòng)這項服務(wù),否則,關(guān)閉這項服務(wù)。
44、yppasswd
讓NIS用戶(hù)能夠修改密碼。運行在NIS域的服務(wù)器上??蛻?hù)端程序同樣也叫yppasswd。
45、ypserv
標準NIS/YP網(wǎng)絡(luò )協(xié)議的一個(gè)實(shí)現。允許主機名,用戶(hù)名和其他信息分布于網(wǎng)絡(luò )各端。運行在NIS服務(wù)器上,客戶(hù)端不需要。
Fedora core 2啟動(dòng)服務(wù)詳解 http://www.gbunix.com/htmldata/2005_06/1/3/article_1227_1.html 最近筆者重裝了一遍Fedora core 2,安裝類(lèi)型為Workstation,沒(méi)有安裝X-Window環(huán)境。安裝完畢后,執行ntsysv對系統所有的啟動(dòng)服務(wù)進(jìn)行設置,發(fā)現有一些服務(wù)比較陌生,所以就就寫(xiě)了這篇文章,對系統所有的啟動(dòng)服務(wù)進(jìn)行一個(gè)簡(jiǎn)單的總結,希望和大家一起來(lái)分享。
服務(wù)名稱(chēng)
含義
acpid
配置文件:/proc/acpi/event
預設端口:無(wú)
說(shuō)明:Advanced Configuration and Power Interface,為替代傳統的APM電源管理標準而推出的新型電源管理標準。
是否需要啟動(dòng):如果你需要對電源進(jìn)行管理,那就需要啟動(dòng)。
anacron
配置文件:/etc/anacron
預設端口:無(wú)
說(shuō)明:一個(gè)自動(dòng)化運行任務(wù)。Red Hat Linux 隨帶四個(gè)自動(dòng)化任務(wù)的工具:cron、 anacron、at、和 batc。當你的Linux主機并不是全天候開(kāi)機,這個(gè)anacron就可以幫你執行在“crontab”設定的時(shí)間內沒(méi)有執行的工作。舉例來(lái)說(shuō),當你的主機在晚上12:00會(huì )自動(dòng)關(guān)閉,但是偏偏crontab這個(gè)例行性工作是在4:00工作,這個(gè)時(shí)候例行性工作就不能起作用了。不過(guò)利用anacron就能做到。
是否需要啟動(dòng):如果主機已經(jīng)24小時(shí)開(kāi)機,而且運行了cron,那么這個(gè)守護程序就不需要啟動(dòng)了。
apmd
配置文件:/etc/sysconfig/apmd
預設端口:無(wú)
說(shuō)明:Advanced Power Management,高級電源管理。傳統的電源管理標準。一般系統都會(huì )同時(shí)支持APM和APMD兩種標志,但系統加載時(shí)只需加載一個(gè)即可。對于筆記本電腦比較有用,可以了解系統的“電池電量”。
是否需要啟動(dòng):如果我們使用的是臺式電腦或一直開(kāi)機的機型,就不需要使用這個(gè)守護程序。
atd
配置文件:/etc/at.allow,/etc/at.deny
預設端口:無(wú)
說(shuō)明:一個(gè)自動(dòng)化運行任務(wù)。
是否需要啟動(dòng):通常需要啟動(dòng)。不過(guò)如果你一直使用cron,那么也可以不啟動(dòng)。
autofs
配置文件:/etc/rc.d/init.d/autofs
預設端口:無(wú)
說(shuō)明:實(shí)現光盤(pán)、軟盤(pán)的自動(dòng)加載。
是否需要啟動(dòng):一般不需要啟動(dòng)。
chargen
chargen-udp
預設端口:TCP/UDP 19
說(shuō)明:Character Generator Protocol,一種網(wǎng)絡(luò )服務(wù),主要功能是提供類(lèi)似遠程打字的功能。
更多細節:http://www.networksorcery.com/enp/RFC/Rfc864.txt
是否需要啟動(dòng):為安全起見(jiàn),盡量關(guān)閉這個(gè)服務(wù)。
cpuspeed
說(shuō)明:監測系統空閑百分比,降低或加快CPU時(shí)鐘速度和電壓從而在系統空閑時(shí)將能源消耗降為最小,而在系統繁忙時(shí)最大化加快系統執行速度。
更多細節:
http://altlinux.org/index.php?module=sisyphus&package=cpuspeed 是否需要啟動(dòng):需要啟動(dòng)。
crond
配置文件:/etc/crontab
預設端口:無(wú)
說(shuō)明:用來(lái)執行例行性命令的守護程序。
是否需要啟動(dòng):必須啟動(dòng)。
cups
配置文件:
CUPS服務(wù)器配置文件:/etc/cups/cupsd.conf
CUPS客戶(hù)端配置文件:/etc/cups/client.conf
CUPS打印機配置文件:/etc/cups/printers.conf
CUPS中類(lèi)(class)配置文件:/etc/cups/classes.conf
說(shuō)明:Common UNIX Printing System,公共UNIX打印支持,為L(cháng)inux提供打印功能。
是否需要啟動(dòng):如果不安裝打印機,就不需要啟動(dòng)。
cups-lpd
預設端口:無(wú)
說(shuō)明:CUPS Line Printer Daemon ("LPD"),提供打印功能。
是否需要啟動(dòng):如果不安裝打印機,就不需要啟動(dòng)。
daytime
daytime-udp
預設端口:TCP 13
說(shuō)明:Daytime協(xié)議(RFC867)是一個(gè)簡(jiǎn)單的協(xié)議,為客戶(hù)機實(shí)現從遠程服務(wù)器獲取日期和時(shí)間的功能。
是否需要啟動(dòng):不用啟動(dòng)。
echo
echo-udp
預設端口:7
說(shuō)明:服務(wù)器回顯客戶(hù)數據服務(wù)。
是否需要啟動(dòng):不用啟動(dòng)。
gpm
配置文件:/etc/sysconfig/mouse
預設端口:無(wú)
說(shuō)明:General Purpose Mouse Daemon ,gpm為文本模式下的Linux程序如mc(Midnight Commander)提供了鼠標的支持。它也支持控制臺下鼠標 的拷貝,粘貼操作以及彈出式菜單。
是否需要啟動(dòng):沒(méi)必要的話(huà),建議不要啟動(dòng)。
iptables
說(shuō)明:防火墻。
是否需要啟動(dòng):必須啟動(dòng)。
irda
Infrared Data Association,是一個(gè)實(shí)現紅外無(wú)線(xiàn)數據傳輸的工業(yè)標準。
irqbalance
對多個(gè)系統處理器環(huán)境下的系統中斷請求進(jìn)行負載平衡的守護程序。
是否需要啟動(dòng):如果你只安裝了一個(gè)CPU,就不需要加載這個(gè)守護程序。
isdn
Integrated Services Digital Network,綜合數字服務(wù)網(wǎng)絡(luò )。提供對isdn設備的支持。
kudzu
配置文件:
/etc/sysconfig/hwconf
/etc/sysconfig/kudzu
說(shuō)明:硬件自動(dòng)檢測程序,會(huì )自動(dòng)檢測硬件是否發(fā)生變動(dòng),并相應進(jìn)行硬件的添加、刪除工作。當系統啟動(dòng)時(shí),kudzu會(huì )對當前的硬件進(jìn)行檢測,并且和存儲在 /etc/sysconfig/hwconf中的硬件信息進(jìn)行一一對照,如果某個(gè)硬件從系統中被添加或者刪除時(shí),那么kudzu就會(huì )察覺(jué)到,并且通知用戶(hù)是否進(jìn)行相關(guān)配置,然后修改/etc/sysconfig/hwconf,使硬件資料與系統保持同步。如果/etc/sysconfig/hwconf這個(gè)文件不存在,那么kudzu將會(huì )從/etc/modprobe.conf,/etc/sysconfig/network-scripts/和 /etc/X11/XF86Config中探測已經(jīng)存在的硬件。
是否需要啟動(dòng):如果啟動(dòng)kudzu,則每次啟動(dòng)系統,都會(huì )檢查新硬件(checking new hardware),會(huì )延長(cháng)系統啟動(dòng)的時(shí)間。如果你不打算增加新硬件,那么就可以關(guān)閉這個(gè)啟動(dòng)服務(wù),以加快系統啟動(dòng)時(shí)間。
mdmonitor
與RAID設備相關(guān)的守護程序。
mdmpd
與RAID設備相關(guān)的守護程序。
messagebus
D-BUS是一個(gè)庫,為兩個(gè)或兩個(gè)以上的應用程序提供一對一的通訊。
dbus-daemon-1是一個(gè)應用程序,它使用這個(gè)庫來(lái)實(shí)現messagebus守護程序。多個(gè)應用程序通過(guò)連接messagebus守護程序可以實(shí)現與其他程序交換信息。
更多細節:
http://www.freedesktop.org/software/dbus/doc/dbus-daemon-1.1.html microcode_ctl
可以編碼以及發(fā)送新的微代碼到kernel以更新Intel IA32系列處理器(Pentium Pro,PII,PIII,Pentium 4,Celeron, Xeon 等等 – 全部 P6 以及更高,不包括 pentium classics)。
更多細節:
http://www.urbanmyth.org/microcode/ http://microcodes.sourceforge.net/ netdump
News Backup Dump Server,遠程備份服務(wù)器。
netfs
Network Filesystem Mounter,安裝和卸載NFS、SAMBA和NCP網(wǎng)絡(luò )文件系統。
netplugd
配置文件:
/etc/netplug/netplugd.conf
/etc/netplug.d/netplug
說(shuō)明:network cable hotplug management daemon,netplugd是一個(gè)守護程序,可以監控一個(gè)或多個(gè)網(wǎng)絡(luò )接口的狀態(tài),當某些事件觸發(fā)時(shí)運行一個(gè)外部腳本程序。
更多細節:http://people.debian.org/~enrico/netplugd.html
network
在系統啟動(dòng)時(shí)激活所有的網(wǎng)絡(luò )接口。
nfs
網(wǎng)絡(luò )文件系統。
nfslock
NFS是一個(gè)流行的通過(guò)TCP/IP網(wǎng)絡(luò )共享文件的協(xié)議,此服務(wù)提供了NFS文件鎖定功能。
ntpd
配置文件:/etc/ntp.conf
說(shuō)明:Network time Protocol daemon,網(wǎng)絡(luò )時(shí)間校正協(xié)議。簡(jiǎn)單的說(shuō),NTP是用來(lái)使系統和一個(gè)精確的時(shí)間源保持時(shí)間同步的協(xié)議。
推薦大家看一篇文章:《NTP-讓網(wǎng)絡(luò )里的電腦時(shí)間精確到毫秒》
發(fā)表在2004年12月份的《在線(xiàn)技術(shù)》雜志第63頁(yè)
pcmcia
Pcmcia卡,支持筆記本電腦的PCMCIA 設備,如調制解調器, 網(wǎng)絡(luò )適配器, SCSI卡等等。
portmap
Portmap守護程序為RPC服務(wù),如NIS和NFS提供動(dòng)態(tài)端口的分配。
psacct
包括幾個(gè)工具用來(lái)監控進(jìn)程活動(dòng)的工具,包括ac,lastcomm, accton 和sa。
random
說(shuō)明:快速的將系統的狀態(tài)在隨機的時(shí)間內存到景象檔案中,對于系統相當重要。因為在開(kāi)機之后,系統會(huì )迅速的恢復到開(kāi)機之前的狀態(tài)。
是否需要啟動(dòng):必須啟動(dòng)。
rawdevices
在使用集群文件系統時(shí)用于加載raw設備的守護程序。
readahead
readahead_early
配置文件:/etc/readahead.early.files /etc/readahead.files
說(shuō)明:readahead和readahead_early是在Fedora core 2中最新推出的兩個(gè)后臺運行的守護程序。其作用是在啟動(dòng)系統期間,將啟動(dòng)系統所要用到的文件首先讀取到內存中,然后在內存中進(jìn)行執行,以加快系統的啟動(dòng)速度。而上面兩個(gè)配置文件就保存著(zhù)將要讀取到內存的文件列表。
rhnsd
Red Hat 網(wǎng)絡(luò )服務(wù)。通知你有關(guān)官方的安全信息以及為你的系統打補丁。
rpcgssd
rpcidmapd
rpcsrcgssd
說(shuō)明:gestion NFS v4,是Linux 2.6內核新添的功能。
是否需要啟動(dòng):不需要啟動(dòng)。
rsync
remote sync,遠程數據備份工具。
saslauthd
使用SASL的認證守護程序。
sendmail
郵件服務(wù)器。
services
一個(gè)內部xinetd服務(wù),用于監聽(tīng)活動(dòng)的服務(wù)。
sgi-fam
實(shí)現實(shí)時(shí)數據鏡像。監控文件的變更,提供一個(gè)應用程序API接口用來(lái)當指定的文件火目錄改變時(shí)及時(shí)通知。
smartd
Self Monitor Analysis and Reporting Technology System,監控你的硬盤(pán)是否出現故障。
sshd
配置文件:
OpenSSH服務(wù)器配置文件:/etc/ssh/sshd_config
OpenSSH客戶(hù)端配置文件:/etc/ssh/ssh_config
預設端口:22
說(shuō)明:Secure Shell Protocol,實(shí)現安全地遠程登陸管理主機。
是否需要啟動(dòng):如果想實(shí)現遠程管理,就需要啟動(dòng)。
syslog
配置文件:/etc/syslog.conf
說(shuō)明:記錄所有的系統行為。
是否需要啟動(dòng):必須啟動(dòng)。
time
從遠程主機獲取時(shí)間和日期,采用TCP協(xié)議。
time-udp
從遠程主機獲取時(shí)間和日期,采用UDP協(xié)議。
vncserver
VNC (Virtual Network Computing,虛擬網(wǎng)絡(luò )計算),它提供了一種在本地系統上顯示遠程計算機整個(gè)“桌面”的輕量型協(xié)議。
更多細節:http://www.realvnc.com/
xfs
預設端口:TCP 7100
說(shuō)明:x font server,X Window字型服務(wù)器,為本地和遠程X服務(wù)器提供字型集。
是否需要啟動(dòng):如果使用run-level為5的圖形界面,那么就需要啟動(dòng)。
xinetd
配置文件:/etc/xinetd.conf
說(shuō)明:xinetd作為inetd的后續版本,負責管理系統中不頻繁使用的服務(wù),這些服務(wù)程序在有請求時(shí)才由xinetd服務(wù)負責啟動(dòng)運行,一旦完成服務(wù)請求服務(wù)程序結束運行,這樣可以有效地減少對系統資源的占用率。通常,xinetd管理的程序有telnet、ftp、rsh和rlogin。關(guān)閉inetd也就關(guān)閉了這些由它管理的服務(wù)。
更多細節:http://www.xinetd.org/
是否需要啟動(dòng):必須啟動(dòng)。
yum
配置文件:/etc/yum.conf
說(shuō)明:Yellow Dog UpdaterModified,是一個(gè)自動(dòng)更新、安裝和刪除RPM軟件包的管理程序,它會(huì )自動(dòng)計算軟件包的管理程序,并判斷哪些軟件應該安裝,哪些軟件則不必安裝。
更多細節:
http://linux.duke.edu/projects/yum/ 是否需要啟動(dòng):以系統管理策略而決定是否啟動(dòng)。
一口氣寫(xiě)了這么多服務(wù),想必大家也看累了吧。大家再檢查一下,還沒(méi)完。眾所周知,為了系統的安全起見(jiàn),我們不可能把所有的服務(wù)都啟動(dòng)了。越簡(jiǎn)單就越安全,一個(gè)系統安裝完畢后,我們只需要啟動(dòng)一些必備的服務(wù)以保證系統能夠正常使用就行了,其余用不到的服務(wù)可以暫時(shí)關(guān)閉。下面是我列出的需要啟動(dòng)的服務(wù)。另,本人水平有限,僅供參考。
acpid:提供高級電源管理。
cpuspeed:可以提高系統運行效率。
crond:執行例行性程序。
Iptables: 防火墻。
Kudzu:自動(dòng)檢測硬件的變更。
Network: 激活網(wǎng)絡(luò )接口。
Random:加快系統的啟動(dòng)。
Readahead和Readahead_early:加快系統的啟動(dòng)。
Syslog:把各類(lèi)事件寫(xiě)入日志。
另外,還有一些服務(wù)筆者還是不太明白,希望大家能幫我解答。這些服務(wù)有:mdmonitor、mdmpd、messagebus、netplugd、 random、rpcgssd、rpcidmapd、rpcsrcgssd、sgi-fam、smartd。如有新的體會(huì ),我會(huì )繼續修改這篇文章的。
參考文獻
[1] 《Linux Daemons and Services》
http://www.sorgonet.com/linux/linuxdaemons/ [2] 《鳥(niǎo)哥的Linux私房菜》
http://www.vbird.org/ [3] 《Red Hat Linux 9 系統管理