/home on btrfs subvolume shared with / stops boot; adding nofail to fstab fixes it

Bug #1987573 reported by Bill
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
systemd (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

After performing `do-release-upgrade` from 20.04 to 22.04.01, the system failed to boot with a message of:

Failed to mount /home
Dependency failed for Local File Systems.

It took some work to figure out, but adding "nofail" to the fstab line allowed boot to proceed, and with that, the system appears to be working without issue.

Both /boot and /home are mounted from subvolumes on the same btrfs filesystem. The working fstab is below:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
LABEL=Root / btrfs defaults,subvol=@ 0 1
LABEL=Root /home btrfs defaults,subvol=@home,nofail 0 2
LABEL=EscherBackup /mnt/EscherBackup btrfs defaults 0 2
LABEL=PicassoBackup /mnt/PicassoBackup btrfs defaults 0 2
LABEL=scratch /mnt/scratch btrfs defaults 0 2
/dev/mapper/cryptswap1 none swap sw 0 0
/dev/mapper/cryptswap2 none swap sw 0 0

ProblemType: Bug
DistroRelease: Ubuntu 22.04
Package: ubuntu-release-upgrader-core 1:22.04.13
ProcVersionSignature: Ubuntu 5.15.0-46.49-generic 5.15.39
Uname: Linux 5.15.0-46-generic x86_64
ApportVersion: 2.20.11-0ubuntu82.1
Architecture: amd64
CasperMD5CheckResult: unknown
CrashDB: ubuntu
Date: Wed Aug 24 20:16:42 2022
EcryptfsInUse: Yes
PackageArchitecture: all
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: ubuntu-release-upgrader
Symptom: release-upgrade
UpgradeStatus: Upgraded to jammy on 2022-08-24 (0 days ago)
VarLogDistupgradeXorgFixuplog:
 INFO:root:/usr/bin/do-release-upgrade running
 INFO:root:No xorg.conf, exiting

Revision history for this message
Bill (bill-launchpad) wrote :
Revision history for this message
Nick Rosbrook (enr0n) wrote :

Since this is not a problem with the upgrade process itself, I am going to assign to btrfs-progs.

Taking a quick look though, is your problem that you have LABEL=Root used twice in your /etc/fstab (it is used for both / and /home)?

affects: ubuntu-release-upgrader (Ubuntu) → btrfs-progs (Ubuntu)
Changed in btrfs-progs (Ubuntu):
status: New → Incomplete
Revision history for this message
Bill (bill-launchpad) wrote :

"Taking a quick look though, is your problem that you have LABEL=Root used twice in your /etc/fstab (it is used for both / and /home)?"

That double-label is correct. Root is mounted from the subvolume @ while home is mounted from the subvolume @home.

The same fstab worked correctly in 20.04.

Revision history for this message
Bill (bill-launchpad) wrote :

Also, I'm not sure, but it may be a systemd issue, too. (Based on the fact that the error message was "Dependency failed for Local File Systems." which I think comes from systemd.)

Revision history for this message
Adam Borowski (kilobyte) wrote :

It works perfectly with sysvinit (in Debian), thus yes, it's a systemd regression. I don't think any of recent changes in btrfs-progs are relevant.

Revision history for this message
Nick Rosbrook (enr0n) wrote :

Bill - Can you please provide more detailed logs from a failed boot (i.e. complete journalctl output from the failed .mount units)?

affects: btrfs-progs (Ubuntu) → systemd (Ubuntu)
Revision history for this message
Bill (bill-launchpad) wrote (last edit ):

The `journalctl -xb` output is attached. The error is noted at time "Aug 29 11:12:19". I had to press Ctrl-D at the right moment during boot so that I could get this output. For clarity, I removed the "nofail" to get this error again, and it is reproducible by adding/removing "nofail".

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for systemd (Ubuntu) because there has been no activity for 60 days.]

Changed in systemd (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.