You should still use /etc/rc.local
unless you yourself can confirm that rc.local
isnt working.
After consulting with micahg (IRC user) who is on bugsquad and bugcontrol, we've confirmed that /etc/rc.local
runs as expected behavior is on 12.04. As the bug you mentioned is "Incomplete", it is likely an edge-case bug and not a bug that is confirmable.
What I would have put on a comment on that bug (but did not after talking with micahg) is this (note that a bunch of it is context-specific for the bug)
rc.local
does indeed boot on a clean 12.04 installation. I have
confirmed that rc.local
does correctly work, after numerous changes to
the file and numerous reboots.
I have 30 different commands which activate or deactivate certain
services, and run specific services that are not in /etc/init.d/
or
upstart. Each and every one of those commands has correctly run (just
tested) on a clean 12.04 installation.
Since /etc/rc.local
requires superuser to edit, i do not think its
getting overwritten or overridden by the desktop, except in certain
circumstances where a graphics driver is taking over settings (or a
GUI taking over settings for instance for backlight or screen
brightness on laptops, which I tend to see happen when a proprietary
graphics card's drivers and software are used), in which case
/etc/rc.local
is most likely being run, but the GUI and relevant software starting
afterwards is running additional commands and directives post-rc.local
runtime.
This needs additional testing with numerous different command
combinations, but expected behaviour of rc.local is indeed occurring
on standard 12.04 and 11.04 tests I have run.
ls -l /etc/rc.local
to the question. – mikewhatever Jul 13 '12 at 13:57I'm pretty sure my commands are ok. They work fine with a sudo at the command line.
– Simon Roberts Jul 13 '12 at 14:37/etc/rc.local
(just below the shebang).exec >/tmp/rc.local-output 2>&1; set -x
Then after booting, see if/tmp/rc.local-output
exists, and if it does, it should contain all commands run (because ofset -x
), and all the script's output and error messages. – geirha Jul 13 '12 at 14:52