The root file system is not checked on startup when using systemd because /etc/fstab contains: rootfs / auto defaults 1 1 In systemd 210, the following message is shown by journalctl: systemd-fstab-generator[68]: Checking was requested for "rootfs", but it is not a device. If /etc/fstab is corrected to be the proper root filesystem device instead of "rootfs", then the following message is shown by journalctl: systemd[1]: Started File System Check on Root Device.
Also, if the "ro" flag is not passed to the kernel to mount the root filesystem readonly on startup, systemd will not run fsck against the root filesystem. You can verify this by running: journalctl | grep fsck If the root filesystem was checked, it should show output similar to: systemd-fsck[79]: /dev/mmcblk0p2: clean, 2451/967680 files, 227258/7739392 blocks
This is likely an upstream issue.
systemd-fsck presumes that devices are mounted under /dev/ and /sys and the 'rootfs' keyword in /etc/fstab is not known to it.
I think we have /etc/fstab problem here root@qemuarm:~# cat /etc/fstab rootfs / auto defaults 1 1 ... 'rootfs' is incorrect here. as per /ets/fstab manpages It could either be one of LABEL, UUID or kernel device name and to specify label the syntax is LABEL=... so that option is out and its clearly not uuid or kernel device name. root@qemuarm:~# ./lsblk -f NAME FSTYPE LABEL UUID MOUNTPOINT sda ext3 9a4ad0c2-3381-4b8c-a03b-26c13fb11f8d / root@qemuarm:~# cat /proc/cmdline root=/dev/sda rw console=ttyAMA0,115200 console=tty ip=192.168.7.2::192.168.7.1:255.255.255.0 mem=128M highres=off console=ttyS0 since we specify root= in kernel cmdline it finds the boot device but since we also have /et/fstab lying around it gets priority when mounting and when generator is trying to generate systemd units out of it for systemd.mount it rightly doesnt know about 'rootfs'
I replaced rootfs with /dev/root in /etc/fstab and it now checks the root filesystem on startup (using systemd 211).
(In reply to comment #5) > I replaced rootfs with /dev/root in /etc/fstab and it now checks the root > filesystem on startup (using systemd 211). OK thats reasonable, please submit a patch for this change to OE-Core.
Fixed by https://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=e8bc7a136a81a0d8df2d32dfba0920c1b2835141