A standard Ubuntu desktop or cloud server installation typically boots in under fifteen seconds. However, system administrators and desktop users occasionally encounter an agonizing boot stall where the system hangs on a blinking cursor or Plymouth splash screen, accompanied by messages such as: A start job is running for dev-disk-by… (1min 30s / no limit) or journal warnings citing System bootup exceeding timeout.
This startup delay is almost always caused by systemd waiting for missing swap partitions, unmounted network shares defined in /etc/fstab, or hanging background services that refuse to release boot synchronization gates. Follow this guide to analyze your boot pipeline and eliminate timeout delays in Ubuntu.
Analyze Boot Bottlenecks Using systemd-analyze
The systemd init system provides built-in instrumentation tools that detail exactly which services, targets, and mount points consumed boot time:
systemd-analyze
systemd-analyze blame
The blame command outputs services sorted by initialization duration. Look for items at the top taking thirty seconds or longer (such as systemd-networkd-wait-online.service, fstrim.service, or specific drive mounts).
To inspect the critical initialization chain, execute:
systemd-analyze critical-chain
Inspect and Repair Missing UUIDs in /etc/fstab
The single most common cause of the dreaded 90-second boot stall is an obsolete UUID in /etc/fstab referencing a swap partition, secondary hard drive, or external storage device that was reformatted, detached, or replaced:
- List all currently connected block devices and their active UUIDs:
sudo blkid - Open your filesystem table in
nano:sudo nano /etc/fstab - Compare the UUIDs listed in
fstabagainst the output ofblkid. - If a line references a drive that is no longer permanently attached, either comment out the line by adding
#at the beginning or add thenofailmount option:
TheUUID=1234-ABCD /mnt/data ext4 defaults,nofail 0 2nofailoption instructs systemd to continue booting immediately if the drive is absent, rather than waiting for the 90-second timeout. - Save (Ctrl + O) and exit (Ctrl + X).
Reduce Default systemd Job Timeout
By default, systemd allows problematic start and stop jobs to run for 90 seconds before timing out. You can safely lower this threshold to 15 seconds to prevent prolonged boot stalls:
- Open the systemd manager configuration file:
sudo nano /etc/systemd/system.conf - Locate the lines:
#DefaultTimeoutStartSec=90s #DefaultTimeoutStopSec=90s - Uncomment both lines (remove
#) and reduce the values:DefaultTimeoutStartSec=15s DefaultTimeoutStopSec=15s - Save the file and reboot your system to verify the accelerated startup sequence.