2

If a fsck takes longer than 90 seconds during boot, the systemd unit times out and the system falls into emergency mode. This is obviously very unfortunate with headless devices without KVM, as the issue cannot not be fixed or atleast diagnosed from the outside.

The exact lines given are:

[ TIME ] Timed out waiting for device dev-disk-by-partuuid-xxx
[DEPEND] Dependency failed for /boot
[DEPEND] Dependency failed for Local File Systems.
[DEPEND] Dependency failed for File System Check on /dev/disk/bypartuuid/xxx

The offending partition is the boot-partition (FAT-filesystem) on a raspberry pi. Even though the partition is only 41MB big, the fs-check takes longer than 90 seconds. I've never had this issue with ext2/3/4-partitions.

How can I fix this issue?

Zulakis
  • 4,191
  • 14
  • 44
  • 75
  • fsck? Your exact lines given say _nothing_ about fsck taking long to run, they're about the _device itself_ taking too long to show up. – user1686 Aug 29 '18 at 08:31
  • @grawity To clarify: All the while continuous lines of fsck progress were printed. – Zulakis Aug 29 '18 at 18:45

1 Answers1

2

I found two methods to fix this:

a)

Increase DefaultTimeoutStartSec and DefaultTimeoutStopSec in /etc/systemd/system.conf.

b)

Add x-systemd.device-timeout=300s to the /etc/fstab options of the offending partition

This did not work:

  • adding a TimeoutSec line to /lib/systemd/system/systemd-fsck@.service
  • adding a JobTimeoutSec line to /lib/systemd/system/local-fs.target
Zulakis
  • 4,191
  • 14
  • 44
  • 75