/etc/init.d script not executed at boot

Asked by Uqbar on 2009-04-30

I've (caused) a problem.
Somehow a script in /etc/init.d (namely, /etc/init.d/maradns) that is also linked in rc2.d ... rc5.d as S19maradns is not executed at boot any more. I cannot the see the process running with ps.
If I execute that script by hand it works perfectly and I can see the process running with ps.
I know I tested a program called sysv-rc-conf but, as far as I remember, I've not touched that boot script "activation". But I won't swear on it.
I can tell that sysv-rc-conf is showing the boot sctipt as "configured" for runlevels 2 to 5.
I've tried even to completely uninstall and re-install the program with no luck.
At the moment I've added that script in my /etc/rc.local, but this is only a workaround.
Is there any hint for the solution?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Uqbar
Solved:
2009-05-06
Last query:
2009-05-06
Last reply:
2009-05-02
Jim J (morlockhq) said : #1

Can you do an ls -asl of the following directories?

ls -asl /etc/init.d/

ls -asl /etc/rc2.d/

ls -asl /etc/rc3.d/

Also, what is the output of the runlevel command?

runlevel

Uqbar (uqbar) said : #2

root@g1s:~# ls -asl /etc/init.d/
total 420
 4 drwxr-xr-x 2 root root 4096 2009-04-30 08:50 .
12 drwxr-xr-x 143 root root 8192 2009-04-30 18:17 ..
 4 -rw-r--r-- 1 root root 1510 2009-03-31 11:01 README
 4 -rwxr-xr-x 1 root root 762 2009-03-25 20:49 acpi-support
 4 -rwxr-xr-x 1 root root 3187 2008-09-26 03:36 acpid
12 -rwxr-xr-x 1 root root 10150 2009-04-08 02:08 alsa-utils
 4 -rwxr-xr-x 1 root root 1297 2008-09-03 01:38 anacron
 4 -rwxr-xr-x 1 root root 2727 2009-04-08 16:39 apparmor
 4 -rwxr-xr-x 1 root root 2630 2009-04-07 01:45 apport
 4 -rwxr-xr-x 1 root root 1018 2009-04-17 09:52 atd
 4 -rwxr-xr-x 1 root root 2590 2009-03-23 11:17 avahi-daemon
 4 -rwxr-xr-x 1 root root 1109 2005-10-27 14:15 binfmt-support
 8 -rwxr-xr-x 1 root root 4524 2009-04-01 10:53 bluetooth
 4 -rwxr-xr-x 1 root root 2231 2009-03-31 11:11 bootlogd
 4 -rwxr-xr-x 1 root root 1299 2009-03-31 11:11 bootlogs.sh
 4 -rwxr-xr-x 1 root root 1206 2009-03-31 11:11 bootmisc.sh
 4 -rwxr-xr-x 1 root root 2031 2009-03-18 04:48 brltty
 4 -rwxr-xr-x 1 root root 3520 2009-03-31 11:11 checkfs.sh
12 -rwxr-xr-x 1 root root 10518 2009-03-31 11:11 checkroot.sh
 4 -rwxr-xr-x 1 root root 1670 2009-01-12 00:54 console-setup
 4 -rwxr-xr-x 1 root root 2653 2008-11-12 16:45 cron
 4 -rwxr-xr-x 1 root root 2526 2009-04-17 11:17 cups
 8 -rwxr-xr-x 1 root root 4632 2009-01-27 15:40 dbus
 8 -rwxr-xr-x 1 root root 8040 2009-03-05 17:31 dkms_autoinstaller
 4 -rwxr-xr-x 1 root root 1235 2009-02-20 18:56 dns-clean
 4 -rwxr-xr-x 1 root root 3598 2009-04-03 10:26 gdm
 8 -rwxr-xr-x 1 root root 5649 2009-04-09 09:23 glibc.sh
 4 -rwxr-xr-x 1 root root 2091 2009-04-03 17:24 hal
 4 -rwxr-xr-x 1 root root 1329 2009-03-31 11:11 halt
 4 -rwxr-xr-x 1 root root 1287 2009-03-31 11:11 hostname.sh
 4 -rwxr-xr-x 1 root root 917 2009-04-06 16:32 hotkey-setup
 8 -rwxr-xr-x 1 root root 5183 2009-02-18 22:41 hwclock.sh
 4 -rwxr-xr-x 1 root root 1404 2009-01-12 00:54 keyboard-setup
 4 -rwxr-xr-x 1 root root 1484 2009-03-31 11:11 killprocs
 4 -rwxr-xr-x 1 root root 2290 2009-03-30 10:37 laptop-mode
 4 -rwxr-xr-x 1 root root 349 2009-03-26 15:43 linux-restricted-modules-common
 4 -rwxr-xr-x 1 root root 2967 2008-12-22 17:18 maradns
 4 -rwxr-xr-x 1 root root 2766 2009-04-15 19:43 microcode.ctl
 4 -rwxr-xr-x 1 root root 1399 2009-03-18 17:02 module-init-tools
 4 -rwxr-xr-x 1 root root 620 2009-03-31 11:11 mountall-bootclean.sh
 4 -rwxr-xr-x 1 root root 1956 2009-03-31 11:11 mountall.sh
 4 -rwxr-xr-x 1 root root 1351 2009-03-31 11:11 mountdevsubfs.sh
 4 -rwxr-xr-x 1 root root 2350 2009-03-31 11:11 mountkernfs.sh
 4 -rwxr-xr-x 1 root root 618 2009-03-31 11:11 mountnfs-bootclean.sh
 4 -rwxr-xr-x 1 root root 2330 2009-03-31 11:11 mountnfs.sh
 4 -rwxr-xr-x 1 root root 1321 2009-03-31 11:11 mountoverflowtmp
 4 -rwxr-xr-x 1 root root 3668 2009-03-31 11:11 mtab.sh
 4 -rwxr-xr-x 1 root root 2417 2009-03-05 16:02 networking
 4 -rwxr-xr-x 1 root root 882 2009-03-31 11:11 ondemand
 4 -rwxr-xr-x 1 root root 2398 2009-03-09 17:46 pcmciautils
 4 -rwxr-xr-x 1 root root 687 2009-01-09 04:19 policykit
 4 -rwxr-xr-x 1 root root 1027 2009-03-20 03:31 postgresql-8.3
 4 -rwxr-xr-x 1 root root 420 2009-02-20 19:25 pppd-dns
 4 -rwxr-xr-x 1 root root 1683 2008-05-10 08:20 preload
 4 -rwxr-xr-x 1 root root 1247 2009-03-18 23:35 procps
 4 -rwxr-xr-x 1 root root 2186 2009-04-09 02:03 pulseaudio
12 -rwxr-xr-x 1 root root 10042 2009-03-31 11:01 rc
 4 -rwxr-xr-x 1 root root 788 2009-03-31 11:11 rc.local
 4 -rwxr-xr-x 1 root root 117 2009-03-31 11:01 rcS
 4 -rwxr-xr-x 1 root root 1758 2009-04-20 14:21 readahead
 4 -rwxr-xr-x 1 root root 2180 2009-04-20 14:21 readahead-desktop
 4 -rwxr-xr-x 1 root root 639 2009-03-31 11:11 reboot
 4 -rwxr-xr-x 1 root root 941 2009-03-31 11:11 rmnologin
 8 -rwxr-xr-x 1 root root 5200 2009-02-27 02:55 rsync
 4 -rwxr-xr-x 1 root root 1713 2009-03-27 09:17 saned
 4 -rwxr-xr-x 1 root root 918 2009-02-11 13:29 screen-cleanup
 4 -rwxr-xr-x 1 root root 2283 2009-03-31 11:11 sendsigs
 4 -rwxr-xr-x 1 root root 590 2009-03-31 11:11 single
 8 -rw-r--r-- 1 root root 4167 2009-03-31 11:11 skeleton
 8 -rwxr-xr-x 1 root root 7294 2009-03-06 09:34 sl-modem-daemon
 4 -rwxr-xr-x 1 root root 3710 2009-01-28 22:25 ssh
 4 -rwxr-xr-x 1 root root 525 2009-03-31 11:11 stop-bootlogd
 4 -rwxr-xr-x 1 root root 1096 2009-03-31 11:11 stop-bootlogd-single
 4 -rwxr-xr-x 1 root root 1063 2009-04-20 14:21 stop-readahead
 4 -rwxr-xr-x 1 root root 2809 2008-12-05 00:41 syslog-ng
 4 -rwxr-xr-x 1 root root 2704 2009-04-10 05:05 system-tools-backends
 4 -rwxr-xr-x 1 root root 3421 2009-04-09 02:32 udev
 4 -rwxr-xr-x 1 root root 1245 2009-04-09 02:32 udev-finish
 4 -rwxr-xr-x 1 root root 2064 2009-04-03 17:52 ufw
 4 -rwxr-xr-x 1 root root 3627 2009-03-31 11:11 umountfs
 4 -rwxr-xr-x 1 root root 2140 2009-03-31 11:11 umountnfs.sh
 4 -rwxr-xr-x 1 root root 1456 2009-03-31 11:11 umountroot
 4 -rwxr-xr-x 1 root root 1815 2009-03-31 11:11 urandom
 4 -rwxr-xr-x 1 root root 2964 2009-02-08 00:12 usplash
 8 -rwxr-xr-x 1 root root 4604 2009-02-26 07:53 wicd
 4 -rwxr-xr-x 1 root root 2327 2009-04-09 03:47 wpa-ifupdown
 4 -rwxr-xr-x 1 root root 1777 2008-12-05 01:44 x11-common
 4 -rwxr-xr-x 1 root root 3143 2008-12-22 17:18 zoneserver
root@g1s:~# ls -asl /etc/rc2.d/
total 20
 4 drwxr-xr-x 2 root root 4096 2009-04-30 08:50 .
12 drwxr-xr-x 143 root root 8192 2009-04-30 18:17 ..
 0 lrwxrwxrwx 1 root root 24 2009-04-24 14:30 K21postgresql-8.3 -> ../init.d/postgresql-8.3
 4 -rw-r--r-- 1 root root 556 2009-03-31 11:02 README
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S01policykit -> ../init.d/policykit
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S10acpid -> ../init.d/acpid
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:55 S10syslog-ng -> ../init.d/syslog-ng
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S12dbus -> ../init.d/dbus
 0 lrwxrwxrwx 1 root root 25 2009-04-24 11:11 S12sl-modem-daemon -> ../init.d/sl-modem-daemon
 0 lrwxrwxrwx 1 root root 13 2009-04-24 11:21 S16ssh -> ../init.d/ssh
 0 lrwxrwxrwx 1 root root 17 2009-04-30 08:50 S19maradns -> ../init.d/maradns
 0 lrwxrwxrwx 1 root root 16 2009-04-24 10:23 S20apport -> ../init.d/apport
 0 lrwxrwxrwx 1 root root 28 2009-04-24 11:10 S20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S20hotkey-setup -> ../init.d/hotkey-setup
 0 lrwxrwxrwx 1 root root 14 2009-04-24 11:44 S20wicd -> ../init.d/wicd
 0 lrwxrwxrwx 1 root root 20 2009-04-30 08:50 S20zoneserver -> ../init.d/zoneserver
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S24hal -> ../init.d/hal
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S25bluetooth -> ../init.d/bluetooth
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S30gdm -> ../init.d/gdm
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S50avahi-daemon -> ../init.d/avahi-daemon
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S50cups -> ../init.d/cups
 0 lrwxrwxrwx 1 root root 20 2009-04-24 10:23 S50pulseaudio -> ../init.d/pulseaudio
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S50rsync -> ../init.d/rsync
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S50saned -> ../init.d/saned
 0 lrwxrwxrwx 1 root root 31 2009-04-24 10:23 S50system-tools-backends -> ../init.d/system-tools-backends
 0 lrwxrwxrwx 1 root root 21 2009-04-24 10:23 S70bootlogs.sh -> ../init.d/bootlogs.sh
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S70dns-clean -> ../init.d/dns-clean
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S70pppd-dns -> ../init.d/pppd-dns
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:23 S89anacron -> ../init.d/anacron
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S89atd -> ../init.d/atd
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S89cron -> ../init.d/cron
 0 lrwxrwxrwx 1 root root 24 2009-04-24 10:23 S90binfmt-support -> ../init.d/binfmt-support
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:55 S95preload -> ../init.d/preload
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:23 S98usplash -> ../init.d/usplash
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S99acpi-support -> ../init.d/acpi-support
 0 lrwxrwxrwx 1 root root 21 2009-04-24 10:23 S99laptop-mode -> ../init.d/laptop-mode
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S99ondemand -> ../init.d/ondemand
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S99rc.local -> ../init.d/rc.local
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S99rmnologin -> ../init.d/rmnologin
 0 lrwxrwxrwx 1 root root 24 2009-04-24 10:23 S99stop-readahead -> ../init.d/stop-readahead
root@g1s:~# ls -asl /etc/rc3.d/
total 20
 4 drwxr-xr-x 2 root root 4096 2009-04-30 08:50 .
12 drwxr-xr-x 143 root root 8192 2009-04-30 18:17 ..
 0 lrwxrwxrwx 1 root root 24 2009-04-24 14:30 K21postgresql-8.3 -> ../init.d/postgresql-8.3
 4 -rw-r--r-- 1 root root 556 2009-03-31 11:02 README
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S01policykit -> ../init.d/policykit
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S10acpid -> ../init.d/acpid
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:55 S10syslog-ng -> ../init.d/syslog-ng
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S12dbus -> ../init.d/dbus
 0 lrwxrwxrwx 1 root root 25 2009-04-24 11:11 S12sl-modem-daemon -> ../init.d/sl-modem-daemon
 0 lrwxrwxrwx 1 root root 13 2009-04-24 11:21 S16ssh -> ../init.d/ssh
 0 lrwxrwxrwx 1 root root 17 2009-04-30 08:50 S19maradns -> ../init.d/maradns
 0 lrwxrwxrwx 1 root root 16 2009-04-24 10:23 S20apport -> ../init.d/apport
 0 lrwxrwxrwx 1 root root 28 2009-04-24 11:10 S20dkms_autoinstaller -> ../init.d/dkms_autoinstaller
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S20hotkey-setup -> ../init.d/hotkey-setup
 0 lrwxrwxrwx 1 root root 14 2009-04-24 11:44 S20wicd -> ../init.d/wicd
 0 lrwxrwxrwx 1 root root 20 2009-04-30 08:50 S20zoneserver -> ../init.d/zoneserver
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S24hal -> ../init.d/hal
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S25bluetooth -> ../init.d/bluetooth
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S30gdm -> ../init.d/gdm
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S50avahi-daemon -> ../init.d/avahi-daemon
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S50cups -> ../init.d/cups
 0 lrwxrwxrwx 1 root root 20 2009-04-24 10:23 S50pulseaudio -> ../init.d/pulseaudio
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S50rsync -> ../init.d/rsync
 0 lrwxrwxrwx 1 root root 15 2009-04-24 10:23 S50saned -> ../init.d/saned
 0 lrwxrwxrwx 1 root root 31 2009-04-24 10:23 S50system-tools-backends -> ../init.d/system-tools-backends
 0 lrwxrwxrwx 1 root root 21 2009-04-24 10:23 S70bootlogs.sh -> ../init.d/bootlogs.sh
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S70dns-clean -> ../init.d/dns-clean
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S70pppd-dns -> ../init.d/pppd-dns
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:23 S89anacron -> ../init.d/anacron
 0 lrwxrwxrwx 1 root root 13 2009-04-24 10:23 S89atd -> ../init.d/atd
 0 lrwxrwxrwx 1 root root 14 2009-04-24 10:23 S89cron -> ../init.d/cron
 0 lrwxrwxrwx 1 root root 24 2009-04-24 10:23 S90binfmt-support -> ../init.d/binfmt-support
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:55 S95preload -> ../init.d/preload
 0 lrwxrwxrwx 1 root root 17 2009-04-24 10:23 S98usplash -> ../init.d/usplash
 0 lrwxrwxrwx 1 root root 22 2009-04-24 10:23 S99acpi-support -> ../init.d/acpi-support
 0 lrwxrwxrwx 1 root root 21 2009-04-24 10:23 S99laptop-mode -> ../init.d/laptop-mode
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S99ondemand -> ../init.d/ondemand
 0 lrwxrwxrwx 1 root root 18 2009-04-24 10:23 S99rc.local -> ../init.d/rc.local
 0 lrwxrwxrwx 1 root root 19 2009-04-24 10:23 S99rmnologin -> ../init.d/rmnologin
 0 lrwxrwxrwx 1 root root 24 2009-04-24 10:23 S99stop-readahead -> ../init.d/stop-readahead
root@g1s:~# runlevel
N 2
root@g1s:~#

Alexander Jones (alex-weej) said : #3

Seems like when maradns runs in the boot sequence, some depended service is not ready yet so it bails. (Yay for SysVInit!)

By the time rc.local is run (right at the end) or if you run it "manually", it works fine.

This is a bug in maradns. Please report it as such.

Uqbar (uqbar) said : #4

I filed a bug: https://bugs.launchpad.net/ubuntu/+source/maradns/+bug/370932
So I'll mark this question as solved just to close it.
The actual solution is yet to come.