Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save codedeep79/fb1496b183855cbb32eb3cf45bdf5385 to your computer and use it in GitHub Desktop.

Select an option

Save codedeep79/fb1496b183855cbb32eb3cf45bdf5385 to your computer and use it in GitHub Desktop.
How to diagnose and fix very slow boot on Ubuntu

Method 1 : Fix very slow boot on Ubuntu to update GRUB so that it passes this option to the kernel automatically on boot:

Edit the file /etc/default/grub file so that the string noresume is included in the GRUB_CMDLINE_LINUX_DEFAULT line, for example: GRUB_CMDLINE_LINUX_DEFAULT="quiet splash noresume"

Run this command to update GRUB: sudo update-grub

Method 2: You can configure the timeout for Start Job and Stop Jobs.

Edit /etc/systemd/system.conf with elevated privileges and change/add two lines that are commented by default from 90 seconds to 5 (or whatever you prefer) and uncomment it:

from:

#DefaultTimeoutStartSec=90s
#DefaultTimeoutStopSec=90s 

to:

DefaultTimeoutStartSec=5s
DefaultTimeoutStopSec=5s

After that, apply the changes by rebuilding your initramfs with the command: sudo update-initramfs -u

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment