Sunday, February 3, 2019

Improve Asus T100TA Linux boot speed

Improve Asus T100TA Linux boot speed

When checking the systemd-analyze tool by running systemd-analyze blame I’ve also noticed that the NetworkManager-wait-online.service took about 8 seconds to start.

It seems that according to https://askubuntu.com/questions/1018576/what-does-networkmanager-wait-online-service-do this can be safely disabled by:

sudo systemctl disable NetworkManager-wait-online.service

Previous boot time:

Startup finished in 2.348s (firmware) + 3.988s (loader) + 6.232s (kernel) + 12.818s (userspace) = 25.387s
graphical.target reached after 12.797s in userspace

New boot time:

Startup finished in 2.080s (firmware) + 4.884s (loader) + 6.282s (kernel) + 4.769s (userspace) = 18.017s

So improvement by ~ 30%.

Written with StackEdit.

Delay in kernel startup when using btrfs

Delay in kernel startup when using btrfs

With btrfs on Asus T100TA I’ve hit very long delay during kernel startup. Like:

jhorak@t100 ~> systemd-analyze  
Startup finished in 2.075s (firmware) + 14.669s (loader) + 36.202s (kernel) + 13.748s (userspace) = 66.697s

The kernel is stuck on scanning for btrfs filesystems message.

The issue is best described there: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1460447

The scan is done because the kernel is looking for the hibernation file. In case you don’t want to use hibernation you can append resume= to the kernel parameters in /etc/default/grub to the GRUB_CMDLINE_LINUX_DEFAULT variable and update grub.cfg by:

sudo update-grub2

Then the next boot will be significantly faster:

jhorak@t100 /e/default> systemd-analyze 
Startup finished in 2.075s (firmware) + 14.669s (loader) + 6.202s (kernel) + 13.748s (userspace) = 36.697s