boot log help in Ubuntu

Tom Metro tmetro-blu-5a1Jt6qxUNc at public.gmane.org
Sat Apr 11 17:42:33 EDT 2009


James Kramer wrote:
> Stupid me thought that I could go to /var/log and look at a the boot messages.
> I would also appreciate an explanation of why I need to jump through
> hoops to get a look at my boot logs.

This bug:
https://bugs.launchpad.net/upstart/+bug/98955

explains why it is broken, and lists a few workarounds. According to my 
notes, I did:

cd /usr/local/src
wget http://launchpadlibrarian.net/11578525/bootlogd_2.86.02.tar.gz
tar xzf bootlogd_2.86.02.tar.gz
cd bootlogd-2.86.02/
debuild -us -uc -b
cd ..
dpkg -i bootlogd_2.86.02_i386.deb
   [...]
   Installing new version of config file /etc/init.d/bootlogd ...
   Installing new version of config file /etc/default/bootlogd ...
   Adding system startup for /etc/init.d/bootlogd ...
    /etc/rcS.d/S12bootlogd -> ../init.d/bootlogd
   Adding system startup for /etc/init.d/stop-bootlogd-single ...
    /etc/rcS.d/S99stop-bootlogd-single -> ../init.d/stop-bootlogd-single
   Adding system startup for /etc/init.d/stop-bootlogd ...
    /etc/rc2.d/S99stop-bootlogd -> ../init.d/stop-bootlogd
    /etc/rc3.d/S99stop-bootlogd -> ../init.d/stop-bootlogd
    /etc/rc4.d/S99stop-bootlogd -> ../init.d/stop-bootlogd
    /etc/rc5.d/S99stop-bootlogd -> ../init.d/stop-bootlogd


(I see the last reboot logged on the machine where I installed it was in 
September 2008, yet the machine has an uptime of 49 days, so the last 
reboot didn't get logged. I also see /etc/default/bootlogd has:
BOOTLOGD_ENABLE=No

which disables logging. And that file - and the associated init script 
that uses it - hasn't been modified since last April. So I'm puzzled why 
it was working back in September and for several prior boots.)


> I edited /etc/default/bootlogd and set it to yes

I'd make sure that the binary exists (/sbin/bootlogd), as it didn't on 
8.04. Check the output of "aptitude show bootlogd", or "aptitude show 
sysvinit". The latter is the official package containing bootlogd, and 
probably what you should use on 8.10 and newer.


> I also had to
> sudo update-rc.d -f bootlogd defaults

The package I installed took care of that.


> sudo less  /var/log/boot

bootlogd, or at least the package I installed, appears to log to 
/var/log/bootmsg (according to the man page, that's the compiled-in 
default), though the init script contains code to roll /var/log/boot on 
system shutdown (an apparent bug).


> ...I am seeing some boot messages flash by on the screen telling me
> that I have a problem with /etc/resolvconf.

I believe I've seen these as well on 8.04. Haven't noticed them on 8.10, 
and haven't tried 9.x yet.

Though I don't currently see anything in /var/log/bootmsg pertaining to 
  resolvconf.

The original message that prompted me to get boot logging working:

* Starting powernowd...
/etc/rc2.d/S20powernowd: line 84: /sys/devices/system/cpu/cpu
0//cpufreq/scaling_governor: No such file or directory

ended up being just sloppy error handling in one of the startup scripts, 
and an innocuous failure (a normal result of hardware that doesn't 
support the daemon).

  -Tom

-- 
Tom Metro
Venture Logic, Newton, MA, USA
"Enterprise solutions through open source."
Professional Profile: http://tmetro.venturelogic.com/





More information about the Discuss mailing list