various ways to start, stop, enable, and disable daemons on linux

* <rant> *

these days, it appears that a gaggle of windoze fools are contributing to the linux distributions. now there a slew of ways to control daemons, oh, except that nowadays, we seem to have borrowed the term service from windows. if this keeps up, i swear i’m going to build my own server distro…

* </rant> *

anyway, i don’t have a slew of machines at my disposal, at the moment, so these will not map exactly to particular distributions. it’s just a list to joggle my memory when i’m fighting with some inanity on a distro that i haven’t used in a long while. they’re in no particular order, either.


  • enable: chmod +x rc.file

  • disable: chmod -x rc.file

  • disable: hide the file, e.g.: create a subdirectory named attic and move it there.

  • start: /etc/rc.d/rc.file start

  • stop: /etc/rc.d/rc.file stop (or, usually, kill cat /var/run/


  • enable: edit the top of the file (the chkconfig section)

  • disable: same (or, of course, hide the file)


  • enable: chkconfig daemon --level 0123456 on #choose levels

  • disable: chkconfig daemon --level 0123456 off #choose levels

  • start: service daemon start

  • stop: service daemon stop


depending upon the version…

  • enable: most distro’s enable when you install

  • disable: add manual to /etc/init/daemon

  • disable: echo manual >/etc/init/daemon.override


there’s some stuff tucked away in there, as well…