:: Re: [DNG] Shutdown/halt versus WiFi…
Forside
Slet denne besked
Besvar denne besked
Skribent: Alessandro Vesely
Dato:  
Til: dng
Emne: Re: [DNG] Shutdown/halt versus WiFi and NFS
On Sat 28/May/2022 10:23:33 +0200 Brad Campbell via Dng wrote:
> Before that, I tried renaming K01network-manager to K06network-manager, to place it after the NFS unmount, but it ran earlier anyway.



That's the wrong way to do it. Start/ stop order is defined by the so called
LSB headers[*]. If the existing LSB header is wrong, you can override it in
/etc/insserv/overrides/.

The files in /etc/rc?.d should then be "compiled" by insserv. That program
runs whenever updating a package requires it, and it is going to undo any
manual fixes. To prevent that, I replaced it with a script like so:

676-north:tmp# file `which insserv`
/sbin/insserv: POSIX shell script, ASCII text executable
677-north:tmp# cat !$
cat `which insserv`
#! /bin/sh
echo "*******************************************************" >&2
echo "insserv: called as $0 $*" >&2
echo "call fix-init instead" >&2
echo "*******************************************************" >&2
exit 0

Where fix-init[†] is a Perl script I coded trying to take into account existing
fixes. Caution: use it if you dare.


Best
Ale
--

[*] https://wiki.debian.org/LSBInitScripts/
[†] http://www.tana.it/sw/fix-init/