[systemd-devel] fsck, /home, btrfs, multiple partitions/drives, boot failure [Ubuntu 15.04]

Andrei Borzenkov arvidjaar at gmail.com
Wed May 27 22:46:53 PDT 2015


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

В Thu, 28 May 2015 08:34:07 +0300
Andrei Borzenkov <arvidjaar at gmail.com> пишет:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> В Thu, 28 May 2015 08:27:30 +0300
> Andrei Borzenkov <arvidjaar at gmail.com> пишет:
> 
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> > 
> > В Wed, 27 May 2015 14:03:10 -0700
> > Roger Binns <rogerb at rogerbinns.com> пишет:
> > 
> > > -----BEGIN PGP SIGNED MESSAGE-----
> > > Hash: SHA1
> > > 
> > > My immediate problem is a boot failure with systemd on Ubuntu 15.04
> > > because of fsck issues (systemd timing out fscking something it
> > > shouldn't).  Prior Ubuntu releases and upstart work just fine.  Martin
> > > Pitt @ Ubuntu said I should bring the issue here in the Ubuntu bug report:
> > > 
> > >   https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1447879
> > > 
> > > I have 6 drives in my system.  Two identical 960GB SSDs (model,
> > > firmware etc all the same, only serial number difference), another two
> > > identical 256GB SSDs (same story), and two spinning drives.
> > > 
> > > Of note is that my root and /home are both btrfs subvolumes of a RAID0
> > > btrfs using the two first SSDs.  /etc/fstab has these two lines for
> > > them (wrapped by email client):
> > > 
> > > UUID=3ff68715-0daa-4e44-8de2-0997f36d8ab6 / btrfs
> > > defaults,autodefrag,compress=lzo,subvol=@ 0 1
> > > 
> > > UUID=3ff68715-0daa-4e44-8de2-0997f36d8ab6 /home btrfs
> > > defaults,autodefrag,compress=lzo,subvol=@home 0 2
> > > 
> > > blkid output mentioning that UUID:
> > > 
> > > /dev/sda1: LABEL="main" UUID="3ff68715-0daa-4e44-8de2-0997f36d8ab6"
> > > UUID_SUB="12243c27-9502-4a1e-b1d1-d1998107b9e4" TYPE="btrfs"
> > > PARTUUID="011a8e03-01"
> > > 
> > > /dev/sdb1: LABEL="main" UUID="3ff68715-0daa-4e44-8de2-0997f36d8ab6"
> > > UUID_SUB="abda2c4f-3346-44e5-b32e-7c1bba0ba728" TYPE="btrfs"
> > > PARTUUID="1537012a-01"
> > > 
> > 
> > Apr 24 14:18:41 workstation systemd[1]: Job dev-disk-by\x2duuid-3ff68715\x2d0daa\x2d4e44\x2d8de2\x2d0997f36d8ab6.device/start timed out.
> > 
> > systemd times out waiting for UUID alias. Neither sda1 nor sdb1 are
> > present in list of active device units. Please show "udevadm info -q
> > all -n sda1" and "udevadm info -q all -n sdb1" after boot.
> > 
> 
> OK, found them in bug report. As expected
> 
> P: /devices/pci0000:00/0000:00:1f.2/ata1/host0/target0:0:0/0:0:0:0/block/sda/sda1
> E: ID_BTRFS_READY=0
> E: SYSTEMD_READY=0
> 
> 
> P: /devices/pci0000:00/0000:00:1f.2/ata2/host1/target1:0:0/1:0:0:0/block/sdb/sdb1
> E: ID_BTRFS_READY=0
> E: SYSTEMD_READY=0
> 
> Something is wrong with scanning for btrfs either in initrd or in
> running system.
> 


Hmm ... looking in kernel, btrfs_scan_one_device tries to open device
exclusively. If device is already mounted, it will likely fail. That
explains ID_BTRFS_READY=0. I suppose, udev should first check whether
device is part of mounted filesystem, at which point it obviously is
present and active.

Or should this logic better go into kernel handling of
BTRFS_IOC_DEVICES_READY?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAlVmq80ACgkQR6LMutpd94xWaACbBPiw4MViBo846fW38o83Wo5U
XGQAnRH0HOlnGAbG+QatWHV3/T5T00Qn
=A2z8
-----END PGP SIGNATURE-----


More information about the systemd-devel mailing list