I played around with LSB-compatible init-scripts under Debian Wheezy (init is from sysvinit package version 2.88dsf-41+deb7u1). My script in the /etc/init.d directory is as follows:root@T60:~# ls -l /etc/init.d/test-script-rwxr-xr-x 1 root root 811 Aug 10 03:18 /etc/init.d/test-scriptroot@T60:~# cat /etc/init.d/test-script#! /bin/sh### BEGIN INIT INFO# Provides:          test# Required-Start:    $all# Required-Stop:     $all# Default-Start:     2 3 4 5# Default-Stop:      0 1 6# Short-Description: test script# Description:       test script### END INIT INFO# always executestouch /var/test-filecase $1 in  start)    echo Starting script test    touch /var/test-file-start    ;;  stop)    echo Stopping script test    touch /var/test-file-stop    ;;  restart)    echo Restarting script test    touch /var/test-file-restart    ;;  force-reload)    echo Force-reloading script test    touch /var/test-file-force-reload    ;;  status)    echo Status of test    touch /var/test-file-status    ;;  *)    echo Usage: /etc/init.d/test-script {start|stop}    exit 1    ;;esacexit 0root@T60:~# As a next step I added symlink to /etc/rc3.d directory:root@T60:~# file /etc/rc3.d/S05test-script/etc/rc3.d/S05test-script: symbolic link to `../init.d/test-script'root@T60:~# Now if I changed my runlevel from 2 to 3 I expected script to be executed, but this did not happen:root@T60:~# who -r         run-level 2  2014-08-01 20:47                   last=Sroot@T60:~# init 3root@T60:~# who -r         run-level 3  2014-08-10 03:27                   last=2root@T60:~# ls -l /var/test*ls: cannot access /var/test*: No such file or directoryroot@T60:~# I am aware that I could use insserv or update-rc.d to install scripts and then they will work as expected. Am I correct that both insserv and update-rc.d take some additional steps when enabling the script besides installing the symlinks? If yes, then which steps?
Install init scripts manually under Debian Wheezy
init script;sysvinit