On Sun, 07 Aug 2016, Andre Majorel wrote: > I'm working on a program to make changes to a daemon's > configuration file. The man page helpfully warns against doing > that without immediately restarting it. > > Do you think the following would work on any Debian system, > regardless of its current run level and choice of init system ? > > 1. run invoke-rc.d daemon-package stop > 2. update config file > 3. run invoke-rc.d daemon-package start
That works, but it doesn't take into account any socket activation or other such functionality (which *is* a bug in invoke-rc.d that has not been fixed yet). You have to manually account for such uses and explicitly disable them as well around the config change, at least for now. -- "One disk to rule them all, One disk to find them. One disk to bring them all and in the darkness grind them. In the Land of Redmond where the shadows lie." -- The Silicon Valley Tarot Henrique Holschuh