On 05/17/2011 10:50 AM, Mariusz Bialonczyk wrote: > Hi > When I was switching to systemd on another debian box I've discovered > a problem related with passno field in fstab. > I have several md partitions (I am using kernel autoassembly for md, > and I am not using initrd). > I have systemd v.25-2 (debian experimental). > > I have the following entries in fstab for my partitions: > UUID=f73bcffa-5b89-4f1d-a296-5f0e6ebf4673 / ext4 > errors=remount-ro 0 1 > UUID=33a13f77-6e5a-4c1e-b959-d891b0a77488 /home ext4 defaults > 0 2 > UUID=45e28f49-1822-4b32-b8a4-2a9ac1bf543e /usr/src ext4 defaults > 0 2 > UUID=8fe78553-ad5e-47f1-8630-bf1fa5d7b608 /var ext4 defaults > 0 2 > UUID=af8133a0-e9a5-4fcf-81e4-c87c2bb50ac8 none swap sw > 0 0 > all of this UUIDs are /dev/md devices - and not counting the mirroring > disk, all of theese partition is on one physical sata disk. > > According to manual all is fine here: > The sixth field, (fs_passno), is used by the fsck(8) program to deter- > mine the order in which filesystem checks are done at reboot time. The > root filesystem should be specified with a fs_passno of 1, and other > filesystems should have a fs_passno of 2. Filesystems within a drive > will be checked sequentially, but filesystems on different drives will > be checked at the same time to utilize parallelism available in the > hardware. If the sixth field is not present or zero, a value of zero > is returned and fsck will assume that the filesystem does not need to > be checked. > > But this cause a problem to systemd when booting: > systemd-fsck[1346]: /dev/md0: clean, 86170/458752 files, 954201/1834480 blocks > systemd-fsck[3078]: /dev/md2: clean, 312227/1966080 files, 2639961/7864304 > blocks (check in 2 mounts) > systemd-fsck[3091]: fsck.ext4: Device or resource busy while trying to open > /dev/md4 > systemd-fsck[3091]: Filesystem mounted or opened exclusively by another > program? > systemd-fsck[3087]: /dev/md1 has been mounted 23 times without being checked, > check forced. > systemd-fsck[3087]: /dev/md1: 8010/983040 files (1.2% non-contiguous), > 2091221/3932144 blocks > Welcome to emergency mode. Use "systemctl default" or ^D to activate default > mode. > Give root password for maintenance > (or type Control-D to continue): > > I am not 100% sure but if I remind correctly, the "busy one" partition > was random within reboots. > > After conversation with Kay Sievers I've set my fstab entries to this: > UUID=f73bcffa-5b89-4f1d-a296-5f0e6ebf4673 / ext4 > errors=remount-ro 0 1 > UUID=33a13f77-6e5a-4c1e-b959-d891b0a77488 /home ext4 defaults > 0 2 > UUID=45e28f49-1822-4b32-b8a4-2a9ac1bf543e /usr/src ext4 defaults > 0 3 > UUID=8fe78553-ad5e-47f1-8630-bf1fa5d7b608 /var ext4 defaults > 0 4 > UUID=af8133a0-e9a5-4fcf-81e4-c87c2bb50ac8 none swap sw > 0 0 > > I changed the passno fields to 1,2,3,4,0 from 1,2,2,2,0 and this fixes > the problem and my system is now bootable: > systemd-fsck[1334]: /dev/md0: clean, 86178/458752 files, 954201/1834480 blocks > systemd-fsck[3025]: /dev/md4: clean, 2675040/57581568 files, > 199580895/230296816 blocks > systemd-fsck[3109]: /dev/md2 has been mounted 28 times without being checked, > check forced. > systemd-fsck[3109]: /dev/md2: 312227/1966080 files (0.4% non-contiguous), > 2639961/7864304 blocks > systemd-fsck[3190]: /dev/md1: clean, 8033/983040 files, 2067703/3932144 blocks > Setting console screen modes. > Skipping font and keymap setup (handled by console-setup). > ... and login prompt after a while > > So the problem is somewhere with passno interpretation (according to > manual it should work, but it doesn't). > > regards,
Hello again I want to bring some new light on this issue. It seems that passno doesn't solve the "busy device" issue (I tested it on debian's systemd v25-2 and also 29-1). >From time to time I've got the following error when starting (maybe about 1/4 >of all reboots): systemd-fsck[572]: fsck.ext4: Device or resource busy while trying to open /dev/md4 systemd-fsck[572]: Filesystem mounted or opened exclusively by another program? But when I reboot another time the system boot up normally. Full screen from this boot process: http://skyboo.net/IMG_8188.JPG It seems that there is a problem with fsck-ing /dev/md devices (race condition?). Any news/tips to solve this? This is very annoying when the host is not always starting :( regards, -- Mariusz Bialonczyk jabber/e-mail: [email protected] http://manio.skyboo.net _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
