Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fsck.f2fs not cooperating with systemd-fsck-root #7

Open
nolange opened this issue Mar 30, 2020 · 1 comment
Open

fsck.f2fs not cooperating with systemd-fsck-root #7

nolange opened this issue Mar 30, 2020 · 1 comment

Comments

@nolange
Copy link

nolange commented Mar 30, 2020

Hello,

I have the problem that a f2fs filesystem together with systemd (and an installed fsck.f2fs) will endlessly reboot. (systemd/systemd#15106)

The fsck.f2fs tool behaves different to the ext variants, and does not seem to support the -a switch,
and fails on a mounted device (by default). ie. it would not help calling fsck from the initramfs either.
fsck tools seem wildy different, but systemd assumes some basic uniformity

systemd version the issue has been seen with

systemd 245 (245)
-PAM -AUDIT -SELINUX -IMA -APPARMOR -SMACK -SYSVINIT -UTMP -LIBCRYPTSETUP -GCRYPT -GNUTLS -ACL -XZ +LZ4 -SECCOMP +BLKID -ELFUTILS +KMOD -IDN2 -IDN -PCRE2 default-hierarchy=unified

fsck.f2fs 1.13.0 (2019-09-24)

the root filesystem is f2fs, mounted read-only from the initrd.
Systemd will endlessly reboot the system as the fsck attempt fails.

The systemd-fsck tool will end up calling fsck.f2fs with the parameter below,
and will fail as this device is mounted (tries to open it in exclusive mode).

$ fsck.f2fs -a /dev/mmcblk0p5; echo $?  
Info: Fix the reported corruption.
Info: Mounted device!
Info: Check FS only on RO mounted device
	Error: Failed to open the device!
255

A workaround would be to force or skip the check

fsck.f2fs -a -f /dev/mmcblk0p5; echo $?   
Info: Fix the reported corruption.
.....
Done: 0.232165 secs
0
@sveyret
Copy link

sveyret commented May 16, 2020

Same problem here (with OpenRC on a Raspberry Pi). I had to disable root partition check in /etc/fstab in order to get my RPi to boot completely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants