On 02/22/2013 10:59 AM, Guus Sliepen wrote:
> Hm. Then it almost sounds as if the ifscheme init script starts before the
> networking script. Can you send me the output of:
> 
> ls -l /etc/rcS.d

total 4
-rw-r--r-- 1 root root 447 Mar 17  2012 README
lrwxrwxrwx 1 root root  21 Aug  4  2012 S01hostname.sh -> ../init.d/hostname.sh
lrwxrwxrwx 1 root root  24 Aug  4  2012 S01mountkernfs.sh -> 
../init.d/mountkernfs.sh
lrwxrwxrwx 1 root root  14 Aug  4  2012 S02udev -> ../init.d/udev
lrwxrwxrwx 1 root root  24 Aug  4  2012 S03keyboard-setup -> 
../init.d/keyboard-setup
lrwxrwxrwx 1 root root  26 Aug  4  2012 S04mountdevsubfs.sh -> 
../init.d/mountdevsubfs.sh
lrwxrwxrwx 1 root root  16 Aug  4  2012 S05hdparm -> ../init.d/hdparm
lrwxrwxrwx 1 root root  20 Jan  2 12:11 S05hwclock.sh -> ../init.d/hwclock.sh
lrwxrwxrwx 1 root root  22 Aug  4  2012 S06checkroot.sh -> 
../init.d/checkroot.sh
lrwxrwxrwx 1 root root  26 Aug  4  2012 S07cryptdisks-early -> 
../init.d/cryptdisks-early
lrwxrwxrwx 1 root root  32 Sep  9 15:05 S08checkroot-bootclean.sh -> 
../init.d/checkroot-bootclean.sh
lrwxrwxrwx 1 root root  14 Aug  4  2012 S08kmod -> ../init.d/kmod
lrwxrwxrwx 1 root root  17 Aug  4  2012 S08mtab.sh -> ../init.d/mtab.sh
lrwxrwxrwx 1 root root  20 Aug  4  2012 S09cryptdisks -> ../init.d/cryptdisks
lrwxrwxrwx 1 root root  20 Aug  4  2012 S10checkfs.sh -> ../init.d/checkfs.sh
lrwxrwxrwx 1 root root  21 Aug  4  2012 S11mountall.sh -> ../init.d/mountall.sh
lrwxrwxrwx 1 root root  31 Aug  4  2012 S12mountall-bootclean.sh -> 
../init.d/mountall-bootclean.sh
lrwxrwxrwx 1 root root  16 Dec 17 12:36 S13procps -> ../init.d/procps
lrwxrwxrwx 1 root root  19 Dec 17 12:36 S13udev-mtab -> ../init.d/udev-mtab
lrwxrwxrwx 1 root root  17 Dec 17 12:36 S13urandom -> ../init.d/urandom
lrwxrwxrwx 1 root root  20 Dec 17 12:36 S14networking -> ../init.d/networking
lrwxrwxrwx 1 root root  18 Dec 17 12:36 S15ifscheme -> ../init.d/ifscheme
lrwxrwxrwx 1 root root  17 Jan 24 17:41 S15rpcbind -> ../init.d/rpcbind
lrwxrwxrwx 1 root root  20 Jan 24 17:41 S16nfs-common -> ../init.d/nfs-common
lrwxrwxrwx 1 root root  21 Jan 24 17:41 S17mountnfs.sh -> ../init.d/mountnfs.sh
lrwxrwxrwx 1 root root  31 Jan 24 17:41 S18mountnfs-bootclean.sh -> 
../init.d/mountnfs-bootclean.sh
lrwxrwxrwx 1 root root  13 Jan 24 17:41 S19kbd -> ../init.d/kbd
lrwxrwxrwx 1 root root  23 Jan 24 17:41 S20console-setup -> 
../init.d/console-setup
lrwxrwxrwx 1 root root  20 Jan 24 17:41 S21alsa-utils -> ../init.d/alsa-utils
lrwxrwxrwx 1 root root  21 Jan 24 17:41 S21bootmisc.sh -> ../init.d/bootmisc.sh
lrwxrwxrwx 1 root root  20 Jan 24 17:41 S21x11-common -> ../init.d/x11-common

> Also, can you send me a copy of your /etc/init.d/ifscheme?

See attachment (stat: Modify: 2009-12-19 00:16:25.000000000 +0100)


Regards,
Pascal
#!/bin/sh
#
### BEGIN INIT INFO
# Provides:          ifscheme
# Required-Start:    ifupdown
# Required-Stop:     ifupdown
# Should-Start:      
# Should-Stop:       
# Default-Start:     S
# Default-Stop:      0 6
# Short-Description: Select default network scheme
### END INIT INFO

NAME=ifscheme
SCHEMEVOLATILE=/etc/network/run/scheme
SCHEMEPERSISTENT=/var/lib/ifscheme/scheme

if [ -f /etc/default/ifscheme ]; then
        . /etc/default/ifscheme
fi

do_start() {
        if [ -n "$BOOT_SCHEME" ]; then
                ifscheme "$BOOT_SCHEME"
        else
                if [ -r $SCHEMEPERSISTENT ]; then
                        read scheme < $SCHEMEPERSISTENT
                        ifscheme "$scheme"
                fi
        fi
}

do_stop() {
        if [ -r $SCHEMEVOLATILE ]; then
                mkdir -p `dirname $SCHEMEPERSISTENT`
                cat $SCHEMEVOLATILE > $SCHEMEPERSISTENT
        else
                rm -f $SCHEMEPERSISTENT
        fi
}

case "$1" in
        start)
                do_start
        ;;
        reload|force-reload|restart)
                do_stop
                do_start
        ;;
        stop)
                do_stop
        ;;
        *)
                echo "Usage: invoke-rc.d $NAME 
{start|stop|reload|force-reload|restart}"
        ;;
esac

exit 0

Reply via email to