Essentially, a daemon is a constantly-running script in the background that performs a set action as frequently as you set it.
Examples of daemons are:
cPanel makes it extremely easy for you to modify your daemons thanks to it convenient and user-friendly interface. You may want to restart a daemon because you want it to run the instance again or to modify its settings after you’ve tweaked it on the UI.
You can restart most services in WHM’s Restart Services interface (Home >> Restart Services).
Sometimes, you may need to get into the command console so you can make sure that cPanel has restarted the daemon.
Before anything else, though, keep the following in mind:
The following example is typical of the contents that you will find in the /etc/rc.d/init.d/ directory:
|root@host [~]# ls /etc/rc.d/init.d/|
./ atd* exim* httpd.tmpeditlib kdcrotate* named* nscd* rawdevices* snmpd* yppasswdd*
../ autofs* filelimits* identd* keytable* netfs* portmap* rstatd* sshd* ypserv*
anacron* bandmin* functions* ipaliases* killall* network* portsentry* rusersd* syslog* ypxfrd*
antirelayd* chkservd* gpm* ipchains* kudzu* nfs* proftpd* rwalld* xfs*
apmd* cpanel3* halt* iptables* lpd* nfslock* radvd* rwhod* xinetd*
arpwatch* crond* httpd@ isdn* mysql* nofsck* random* single* ypbind*
Take note of the following files:
Run these files as scripts to restart a daemon. For example, if you need to restart the named (BIND) daemon, run the following command as the root user:
You should see the script start up, with a green [OK] message on the left side of the terminal window. If you see a red [FAILED] message, run the following command to check the /var/log/messages file:
The error message will display. If you cannot fix it yourself, submit a ticket to cPanel and the support team will get back to you immediately. Some of these services have many options. For example, if you have several domains that are on your DNS server and you do not want to stop and restart the named daemon because you edited one domain, run the following command:
If you make a minor change to the /usr/local/apache/conf/httpd.conf file, but do not want to restart it, run the following command to perform a graceful restart:
It’s important to remember that a graceful restart finishes current requests before it kills the child processes.