0

This question already has an answer here:

What command do I use to determine how long my actual boot time is? From the grub screen until all the start up processes are finished in the background. I ask because Launcher stays purple for at least another minute or so after I have desktop use. So, I wait until I see it change to the color that matches the theme in use before I begin my session.

The next logical step would be to analyse the boot time data, determine if there are errors, fix, and stream line it.

marked as duplicate by karel, Eric Carvalho, Fabby, dessert, ravery Nov 24 '17 at 10:41

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1

Generally 'dmesg' has the seconds-since-boot time stamp in the left hand column. So 'dmesg | head' should show that all the first events occurred within 0.000000 seconds since the kernel started. Running 'dmesg | tail' immediately after you login should give a pretty good idea. /var/log/kern.log has this same info but each seconds-since-boot stamp is accompanied by the system time as well, so logging in, running 'date' and doing some arithmetic will give you a what might be a more reliable approximation, depending on exactly what you're looking for. The number you're looking for is subject to interpretation. You may be looking for the time it takes before you are given a login prompt, or the time it takes between startup and running your first interactive command, or you may want to know how much time passes before init starts and this gives you a chance to run user-space code via the startup scripts, etc.

  • This is pretty cool, I like that everything is listed by device or interface etc. Now how do I use this information to help me find trouble or streamline the boot process? – xtrchessreal Aug 22 '15 at 22:42
  • 1
    You can use it to see what takes the longest to complete. Typically, long boot times are caused by processes that require resources that aren't yet present or that will never exist. I have seen ntp hang a boot process because it can't find the time servers it's been configured to use or perhaps your machine expects to be given an IP address from a nonexistent DHCP server. Look at the left column to find large time gaps then find the associated software and research it. – user5236609 Aug 22 '15 at 23:35
0

You might want to take a look at BootChart. It has probably more features than you need, but from what I remember has what you are looking for.

http://ccm.net/faq/4268-ubuntu-monitor-your-boot-sequence-with-bootchart

  • I downloaded this app but it does not seem to work, The Dev Website has moved to Github from Google. There is no explanation of how to use it, commands, configs,... I used terminal and looked for a shortcut icon. If you use this app could you please explain further and add some examples or details that help me? – xtrchessreal Aug 22 '15 at 22:20
-1

Type in console;

last -x | grep boot

and also you may want to use;

last -x | grep shutdown last -x | grep reboot

For boot inf;

cat var/log/boot.log or less var/log/boot.log

  • What is the output telling me? How do I interpret the information? The last line concerning boot.log states it cannot find the file. – xtrchessreal Aug 22 '15 at 22:29
  • reboot system boot 3.13.0-32-generi Sun Aug 23 02:18 - 02:18 (00:00) this is my last boot inf. Less than a minute ;02:18 - 02:18. cat var/log/boot.log tells you inf of services which is opened during boot – meto Aug 22 '15 at 23:19

Not the answer you're looking for? Browse other questions tagged or ask your own question.