1

For example, vnStat has the following script instructions:

Usage: /etc/init.d/S32vnstat (start|stop|restart|check|kill|reconfigure)

What happens when I run /etc/init.d/S32vnstat reconfigure?

  • 3
    Have a look at /etc/init.d/S32vnstat to find out. – michas Feb 8 '15 at 12:06
  • That;s specific to each init script. Some dont have it. – muru Feb 8 '15 at 12:13
3

Init scripts are individual to each package, but the convention is that "reconfigure" asks the daemon to re-read the configuration file of the service without interrupting the service provided by the daemon.

Under the hood this is usually implemented as

kill -HUP `cat /run/$PROGRAM.pid`

as sending a daemon a SIGHUP is the usual convention for asking a running daemon to reload its configuration file.

Many daemons cannot do hitless reconfiguration, and some init scripts simply stop && start the service instead, so don't rely upon the existence of the "reconfigure" option to positively imply a hitless reconfiguration feature.

  • The convention for init.d scripts is that this action is called "reload", not "reconfigure". There is also the semi-standard "force-reload" which is supposed to mean reload the service even if it means it has to be restarted. The init script the OP is asking about is not following the convention. – Celada Feb 9 '15 at 7:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.