Log boot fail/error messages in Ubuntu
Log boot fail/error messages in Ubuntu
I'm sure we have all seen error or fail messages while ubuntu is starting (server or desktop version). Because Ubuntu really loads fast sometimes we don't have enough time to actually read what module fail to load or what is causing errors. We can only glance at [ fail ]
Something like:

It's really easy to log the boot fail or error messages. An they might be really useful to read once the system as started.
open the Terminal Window and write:
$ sudo nano /etc/default/bootlogd
nano text editor will open bootlogd configuration file and there you will find these 2 lines:
# Run bootlogd at startup
BOOTLOGD_ENABLE=No
To activate the boot log just change the last line to:
BOOTLOGD_ENABLE=yes
now press Ctrl X to save.
The next time you restart, /var/log/boot will be createad.
To read the log just open the Terminal Window and write
$ sudo nano /var/log/boot
if everything is ok you will only find one line saying:
