Difference between revisions of "Daemons"

From ArchWiki
Jump to: navigation, search
(remove initscripts stuff as systemd is now the default)
m
(17 intermediate revisions by 7 users not shown)
Line 3: Line 3:
 
[[cs:Daemon]]
 
[[cs:Daemon]]
 
[[de:Daemons]]
 
[[de:Daemons]]
 +
[[es:Daemon]]
 
[[it:Daemon]]
 
[[it:Daemon]]
 +
[[ja:Daemons]]
 
[[pl:Daemon]]
 
[[pl:Daemon]]
 
[[ro:Daemon]]
 
[[ro:Daemon]]
Line 9: Line 11:
 
[[tr:Artsüreç]]
 
[[tr:Artsüreç]]
 
[[zh-CN:Daemon]]
 
[[zh-CN:Daemon]]
A [[Wikipedia:Daemon (computing)|daemon]] is a program that runs in the background, waiting for events to occur and offering services. A good example is a web server that waits for a request to deliver a page or a ssh server waiting for someone trying to log in. While these are full featured applications, there are daemons whose work is not that visible. Daemons are for tasks like writing messages into a log file (e.g. {{ic|syslog}}, {{ic|metalog}}) or keeping your system time accurate (e.g. [[Network Time Protocol daemon|{{ic|ntpd}}]]). For more information see {{ic|man 7 daemon}}.
+
A [[Wikipedia:Daemon (computing)|daemon]] is a program that runs as a "background" process (without a terminal or user interface), commonly waiting for events to occur and offering services. A good example is a web server that waits for a request to deliver a page, or a ssh server waiting for someone trying to log in. While these are full featured applications, there are daemons whose work is not that visible. Daemons are for tasks like writing messages into a log file (e.g. {{ic|syslog}}, {{ic|metalog}}) or keeping your system time accurate (e.g. [[Network Time Protocol daemon|{{ic|ntpd}}]]). For more information see {{ic|man 7 daemon}}.
  
{{Note|The word daemon is sometimes used for a class of programs that are started at boot but have no process which remains in memory.  They are called daemons simply because they utilize the same startup/shutdown framework (e.g. systemd service files of Type oneshot) used to start traditional daemons.  For example, the service files for {{ic|alsa}} provides persistent configuration support for its kernel modules but do not start additional background processes to service requests or respond to events.
+
{{Note|The word daemon is sometimes used for a class of programs that are started at boot but have no process which remains in memory.  They are called daemons simply because they utilize the same startup/shutdown framework (e.g. systemd service files of Type oneshot) used to start traditional daemons.  For example, the service files for {{ic|alsa-store}} and {{ic|alsa-restore}} provide persistent configuration support but do not start additional background processes to service requests or respond to events.
  
 
From the user's perspective the distinction is typically not significant unless the user tries to look for the "daemon" in a process list.
 
From the user's perspective the distinction is typically not significant unless the user tries to look for the "daemon" in a process list.
 
}}
 
}}
  
==Systemd system==
+
==Managing daemons==
 +
In Arch Linux, daemons are managed by [[systemd]]. The [[systemd#Basic systemctl usage|systemctl]] command is the user interface used to manage them. It reads ''<service>''.service files that contain information about how and when to start the associated daemon. Service files are stored in {{ic|/{etc,usr/lib,run}/systemd/system}}. See [[systemd#Using units]] for complete information about using systemctl to manage daemons.
  
===Starting on Boot===
+
===Starting on boot===
A default install of Arch Linux will leave you with very few services (or daemons) enabled during boot. You can add or remove services to be started on boot by calling
+
To add or remove services to be started at boot-time, use {{ic|systemctl enable<nowiki>|</nowiki>disable ''<service_name>''}}
  
# systemctl enable <name>
+
===Starting manually===
 +
To start or stop services at runtime, use {{ic|systemctl start<nowiki>|</nowiki>stop ''<service_name>''}}.
  
or
+
===Restarting===
 +
To restart services, use {{ic|systemctl restart ''<service_name>''}}.
  
# systemctl disable <name>
+
===Status reporting===
 +
To report the current status of a service, use {{ic|systemctl status ''<service_name>''}}.
  
The services themselves contain the necessary ordering information, so there is no need to order them manually.
+
==List of daemons==
 
+
See [[Daemons List]] for a list of daemons with the name of the service and legacy rc.d script.
Service files are stored in {{ic|/{etc,usr/lib,run}/systemd/system}}. You can print the list of all the available services on your system, along with their current status, with:
+
$ systemctl list-unit-files
+
 
+
To see a list of running units (some of which will be daemons, amongst other things), type:
+
$ systemctl list-units
+
To see all available ones, add {{ic| --all}} to the end of a command.
+
 
+
To start or stop services at runtime, you can replace enable/disable by start/stop in the above command.
+
 
+
You can read more at the [[Systemd#Systemd_commands]] section.
+
 
+
===Essentials===
+
You do not have to add any more services, if you do not feel the need. However, a typical desktop user will add at least [[CUPS]] and a desktop manager such as [[gdm]] or [[KDM|kdm]]. As you install new services, you will have to manually enable them if you want them to be started on boot.
+
 
+
==List of Daemons==
+
Here is a list of daemons. Note that any package can provide a daemon, so this list will never be complete. Please feel free to add any missing daemons here, in alphabetical order.
+
For each daemon the name of the script (for [[rc.conf|initscripts]]) and of the service (for [[systemd]]) is given.
+
{| border="1"
+
!initscripts!!systemd!!Description
+
|-
+
|[[acpid]]||acpid.service||Delivers ACPI events.
+
|-
+
|[[Advanced Linux Sound Architecture|alsa]]||alsa-store.service
+
alsa-restore.service
+
||Advanced Linux Sound Architecture; provides device drivers for sound cards.
+
|-
+
|atd||atd.service||Run jobs queued for later execution.
+
|-
+
|[[Avahi|avahi-daemon]]||avahi-daemon.service||Allows programs to automatically find local network services.
+
|-
+
|[[Avahi|avahi-dnsconfd]]||avahi-dnsconfd.service||
+
|-
+
|[[Bitlbee|bitlbee]]||bitlbee.service||BitlBee IRC/IM gateway.
+
|-
+
|[[Chrony|chrony]]||chrony.service||Alternative NTP client/server designed for systems not online all the time.
+
|-
+
|[[ClamAV|clamav]]||clamd.service
+
freshclamd.service
+
||Antivirus.
+
|-
+
|[[CPU_Frequency_Scaling|cpupower]]||cpupower.service||Userspace tools for the kernel cpufreq subsystem
+
|-
+
|craftbukkit||''not yet implemented''||CraftBukkit Minecraft server
+
|-
+
|[[Cron|crond]]||cronie.service||Daemon to schedule and time events. The daemon name ''crond'' is used by at least two packages, {{Pkg|cronie}} and {{Pkg|dcron}}.
+
|-
+
|[[CUPS|cupsd]]||cupsd.service
+
''or'' cups.service
+
||Common UNIX Printing System daemon.
+
|-
+
|[[D-Bus|dbus]]||dbus.service||Message bus system for software communication.
+
|-
+
|[[Cron|dcron]]||dcron.service||Daemon to schedule and time events. The daemon name ''crond'' is used by at least two packages, {{Pkg|cronie}} and {{Pkg|dcron}}. {{Pkg|cronie}} is the default cron implementation for Arch.
+
|-
+
|[[Deluge|deluged]]||deluged.service||Cross-platform and full-featured BitTorrent client.
+
|-
+
|[[Deluge|deluge-web]]||deluge-web.service||Cross-platform and full-featured BitTorrent client web UI.
+
|-
+
|[[Dovecot|dovecot]]||dovecot.service||IMAP and POP3 server.
+
|-
+
|[[Dropbox|dropboxd]]||''not yet implemented''||Cross-platform file synchronisation with version control.
+
|-
+
|[[FAM|fam]]||''deprecated''||File Alteration Monitor. (deprecated)
+
|-
+
|fancontrol||fancontrol.service||Fan control daemon (part of lm_sensors)
+
|-
+
|[[Fbsplash|fbsplash]]||''not yet implemented''||Graphical boot splash screen for the user.
+
|-
+
|ftpd||''not yet implemented''||Inetutils ftp daemon
+
|-
+
|[[GDM|gdm]]||gdm.service||Gnome Display Manager (Login Screen)
+
|-
+
|[[Git|git-daemon]]||git-daemon.socket||GIT daemon
+
|-
+
|[[Console Mouse Support|gpm]]||gpm.service||Console mouse support.
+
|-
+
|[[HAL|hal]]||''deprecated''||Hardware Abstraction Layer. (Deprecated)
+
|-
+
|hddtemp||hddtemp.service||Hard drive temperature monitor daemon
+
|-
+
|healthd||healthd.service||A daemon which can be used to alert you in the event of a hardware health monitoring alarm (part of lm_sensors).
+
|-
+
|-
+
|iptables||iptables.service||Load firewall rules.
+
|-
+
|-
+
|ip6tables||ip6tables.service||Load firewall rules for ipv6.
+
|-
+
|[[LAMP|httpd]]||httpd.service
+
See [[Systemd/Services#apache2]] for manual configuration.
+
||Apache HTTP Server (Web Server)
+
|-
+
|[[hwclock]]||||Not a daemon as such, but on shutdown, updates hwclock to compensate for drift. Only run this daemon if ntpd is not running as both daemons adjust the hardware clock.
+
|-
+
|irqbalance||''not yet implemented''||Irqbalance is the Linux utility tasked with making sure that interrupts from your hardware devices are handled in as efficient a manner as possible.
+
|-
+
|[[KDE|kdm]]||kdm.service||KDE Display Manager (Graphical Login)
+
|-
+
|krb5-kadmind||krb5-kadmind.service||Kerberos 5 administration server
+
|-
+
|krb5-kdc||krb5-kdc.service||Kerberos 5 KDC
+
|-
+
|krb5-kpropd||krb5-kpropd.service||Kerberos 5 propagation server
+
|-
+
|[[Laptop Mode Tools|laptop-mode]]||laptop-mode-tools.service||Laptop Power Saving Tools
+
|-
+
|[[lighttpd]]||lighttpd.service||Lighttpd HTTP Server (Web Server).
+
|-
+
|[[LXDE|lxdm]]||lxdm.service||LXDE Display Manager (Graphical Login)
+
|-
+
|mdadm||mdadm.service||MD Administration (Linux Software RAID).
+
|-
+
|[[Music Player Daemon|mpd]]||mpd.service||Music Player Daemon.
+
|-
+
|[[MySQL|mysqld]]||mysqld.service||MySQL database server.
+
|-
+
|[[BIND|named]]||named.service||The Berkeley Internet Name Daemon (BIND) DNS server.
+
|-
+
|netfs||''unused, handled automatically, see''
+
remote-fs.target
+
''to manually execute scripts''
+
||Mounts network file systems.
+
|-
+
|[[Netcfg|net-auto-wired]]||net-auto-wired.service||Netcfg replacement for {{ic|network}} - connects to wired network
+
|-
+
|[[Netcfg|net-auto-wireless]]||net-auto-wireless.service||Netcfg replacement for {{ic|network}} - connects to wireless network
+
|-
+
|[[Netcfg|net-profiles]]||netcfg.service
+
netcfg@<profile-name>.service
+
||Netcfg replacement for {{ic|network}} - connects to profiles
+
|-
+
|[[Configuring_Network|network]]||''(dynamic Ethernet)'' dhcpcd@<interface>.service||To bring up the network connections.
+
|-
+
|[[NetworkManager|networkmanager]]||NetworkManager.service
+
NetworkManager-wait-online.service
+
||Replaces {{ic|network}}, and provides configuration and detection for automatic network connections.
+
|-
+
|[[Nginx|nginx]]||nginx.service||Nginx HTTP Server and IMAP/POP3 proxy server (Web Server)
+
|-
+
|nscd||nscd.service||Name service cache daemon
+
|-
+
|[[Network Time Protocol daemon|ntpd]]||ntpd.service||Network Time Protocol daemon (client and server).
+
|-
+
|[[Ntop|Ntop]]||ntop.service||Ntop is a network traffic probe based on libcap.
+
|-
+
|[[OpenNTPD|openntpd]]||openntpd.service||alternate Network Time Protocol daemon (client and server).
+
|-
+
|osspd||osspd.service||OSS Userspace Bridge.
+
|-
+
|[[Pdnsd|pdnsd]]||pdnsd.service||Proxy DNS server with permanent caching.
+
|-
+
|[[Nginx#1st_Method_.22New.22_.28as_of_PHP_5.3.3.29|php-fpm]]||php-fpm.service||FastCGI Process Manager for PHP
+
|-
+
|[[PostgreSQL|postgresql]]||postgresql.service||PostgreSQL database server.
+
|-
+
|[[Postfix|postfix]]||postfix.service||
+
|-
+
|[[powernowd]]||''not yet implemented''||To adjust speed of CPU depending on system load. See also [[CPU Frequency Scaling]]
+
|-
+
|[[Prosody|prosody]]||prosody.service||XMPP server.
+
|-
+
|ppp||''not yet implemented''||A daemon which implements the Point-to-Point Protocol for dial-up networking.
+
|-
+
|[[preload]]||preload.service||Makes applications run faster by prefetching binaries and shared objects.
+
|-
+
|[[psd]]||psd.service||Manages your browser's profile in tmpfs and periodically sync it back to your physical disk.
+
|-
+
|pure-ftpd||''not yet implemented''||FTP server.
+
|-
+
|[[readahead]]||systemd-readahead-collect.service
+
systemd-readahead-done.service
+
 
+
systemd-readahead-drop.service
+
 
+
systemd-readahead-replay.service
+
||Readahead for faster boot
+
|-
+
||rfkill||rfkill.service||(Un)block radio devices. (.service does not seem to provide equivalent functionality.)
+
|-
+
|[[Rsync|rsyncd]]||rsyncd.service||Rsync daemon.
+
|-
+
|[[Rsyslog|rsyslogd]]||rsyslog.service||The latest version of a system logger.
+
|-
+
|[[samba]]||smbd.service
+
nmbd.service
+
 
+
winbindd.service
+
||File and print services for Microsoft Windows clients.
+
|-
+
|[[USB_Scanner_Support|saned]]||saned@.service||To share the scanner system over network.
+
|-
+
|sensord||sensord.service||Sensor information logging daemon (part of lm_sensors)
+
|-
+
|[[Lm sensors|sensors]]||lm_sensors.service||Hardware (temperature, fans etc) monitoring.
+
|-
+
|[[SLiM|slim]]||slim.service||Simple Login Manager
+
|-
+
|[[SMART|smartd]]||smartd.service||Self-Monitoring, Analysis, and Reporting Technology (S.M.A.R.T) Hard Disk Monitoring
+
|-
+
|snmpd||''not yet implemented''||A suite of applications used to implement SNMP
+
|-
+
|soundmodem||''not yet implemented''||Multiplatform Soundcard Packet Radio Modem
+
|-
+
|[[SOHO Postfix|spamd]]||spamassassin.service|| e-mail spam filtering service.
+
|-
+
|[[Secure Shell|sshd]]||sshd.service
+
sshd@.service
+
 
+
sshdgenkeys.service
+
||OpenSSH (secure shell) daemon.
+
|-
+
|stbd||''deprecated''||This daemon was previously necessary for gnome-system-tools.  However, as of gnome-tools 2.28, it is no longer needed.
+
|-
+
|svnserve||svnserve.service||Subversion server
+
|-
+
|syslogd||''deprecated''||This was the older and basic system logger.
+
|-
+
|[[syslog-ng]]||syslog-ng.service||System logger next generation.
+
|-
+
|[[Timidity|timidity++]]||''not yet implemented''||Software synthesizer for MIDI.
+
|-
+
|[[Transmission|transmissiond]]||transmission.service||Bit Torrent Daemon.
+
|-
+
|[[Ufw|ufw]]||ufw.service||Uncomplicated FireWall.
+
|-
+
|[[VirtualBox|vboxservice]]||vboxservice.service||VirtualBox Guest Service
+
|-
+
|[[Very Secure FTP Daemon|vsftpd]]||vsftpd.service
+
vsftpd@.service
+
 
+
vsftpd-ssl.service
+
||FTP server.
+
|-
+
|[[wicd]]||wicd.service||Combine with dbus to replace {{ic|network}}, a lightweight alternative to NetworkManager.
+
|-
+
|[[x11vnc]]||''not yet implemented''||VNC remote desktop daemon
+
|-
+
|}
+
  
 
==See also==
 
==See also==
 
* [[Systemd|systemd]]
 
* [[Systemd|systemd]]
 
* Examples for writing [[Systemd/Services]]
 
* Examples for writing [[Systemd/Services]]

Revision as of 13:22, 8 February 2013

A daemon is a program that runs as a "background" process (without a terminal or user interface), commonly waiting for events to occur and offering services. A good example is a web server that waits for a request to deliver a page, or a ssh server waiting for someone trying to log in. While these are full featured applications, there are daemons whose work is not that visible. Daemons are for tasks like writing messages into a log file (e.g. syslog, metalog) or keeping your system time accurate (e.g. ntpd). For more information see man 7 daemon.

Note: The word daemon is sometimes used for a class of programs that are started at boot but have no process which remains in memory. They are called daemons simply because they utilize the same startup/shutdown framework (e.g. systemd service files of Type oneshot) used to start traditional daemons. For example, the service files for alsa-store and alsa-restore provide persistent configuration support but do not start additional background processes to service requests or respond to events.

From the user's perspective the distinction is typically not significant unless the user tries to look for the "daemon" in a process list.

Managing daemons

In Arch Linux, daemons are managed by systemd. The systemctl command is the user interface used to manage them. It reads <service>.service files that contain information about how and when to start the associated daemon. Service files are stored in /{etc,usr/lib,run}/systemd/system. See systemd#Using units for complete information about using systemctl to manage daemons.

Starting on boot

To add or remove services to be started at boot-time, use systemctl enable|disable <service_name>

Starting manually

To start or stop services at runtime, use systemctl start|stop <service_name>.

Restarting

To restart services, use systemctl restart <service_name>.

Status reporting

To report the current status of a service, use systemctl status <service_name>.

List of daemons

See Daemons List for a list of daemons with the name of the service and legacy rc.d script.

See also