This looks a lot like an issue with zfs-linux to me (and *maybe*
systemd, not sure about this).
The issue is that the snaps are on /var/lib/snapd/snaps and snapd writes
mount units into /etc/systemd/system/ so that the snaps are mounted
under /snap/<snapname>/<rev>.
Looking at a zfs-linux system and the "mount" output /var/lib is
mounted:
$ mount |grep var/lib
rpool/ROOT/ubuntu_azzm5v/var/lib on /var/lib type zfs
(rw,relatime,xattr,posixacl)
and the systemd unit for this mount point is auto-generated:
$ systemctl status var-lib.mount
var-lib.mount - /var/lib
Loaded: loaded (/proc/self/mountinfo)
Active: active (mounted) since Tue 2021-04-06 16:38:58 CEST; 19min ago
Where: /var/lib
What: rpool/ROOT/ubuntu_azzm5v/var/lib
Systemd should order mounts so that var-lib.mount is mounted before
What=/var/lib/snapd/... is used. I see a zfs-generator in the zfs-linux
source tree that looks like it should generator the mount entries from
the pool. However nothing generated in /run/systemd/generator:
$ find /run/systemd/generator
/run/systemd/generator
/run/systemd/generator/netplan.stamp
/run/systemd/generator/openvpn.service.wants
/run/systemd/generator/local-fs.target.wants
/run/systemd/generator/local-fs.target.wants/systemd-remount-fs.service
/run/systemd/generator/swap.target.requires
/run/systemd/generator/swap.target.requires/dev-disk-by\x2duuid-9c43c866\x2dbe89\x2d499c\x2d9300\x2d098d5dcb0509.swap
/run/systemd/generator/dev-disk-by\x2duuid-9c43c866\x2dbe89\x2d499c\x2d9300\x2d098d5dcb0509.swap
/run/systemd/generator/boot-grub.mount
/run/systemd/generator/local-fs.target.requires
/run/systemd/generator/local-fs.target.requires/boot-grub.mount
/run/systemd/generator/local-fs.target.requires/boot-efi.mount
/run/systemd/generator/boot-efi.mount
We could easily workaround this via Pawels approach above but I feel this will
affect more than snapd. Everyone who wants to mount anyting under /var/lib will
be affected.
--
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to zfs-linux in Ubuntu.
https://bugs.launchpad.net/bugs/1922293
Title:
Snaps appear broken on 21.04 Beta with ZFS
Status in snapd package in Ubuntu:
Confirmed
Status in zfs-linux package in Ubuntu:
Confirmed
Bug description:
I've attempted to use two different userland snaps (qownnotes and
keepassxc) neither function. When attempting to launch I get the
following error:
```
chalbersma@abdos:~$ qownnotes
cannot perform operation: mount --rbind /dev /tmp/snap.rootfs_t3kehe//dev: No
such file or directory
```
Additionally the snaps installed "by default" have a note of "broken"
next to them :
```
chalbersma@abdos:~$ sudo snap list
Name Version Rev Tracking Publisher Notes
core18 1997 latest/stable canonical✓ broken
gnome-3-34-1804 66 latest/stable/… canonical✓ broken
gtk-common-themes 1514 latest/stable/… canonical✓ broken
qownnotes 21.3.9 8183 latest/stable pbek -
snap-store 518 latest/stable/… canonical✓ broken
snapd 11402 latest/stable canonical✓ broken
```
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1922293/+subscriptions
--
Mailing list: https://launchpad.net/~kernel-packages
Post to : [email protected]
Unsubscribe : https://launchpad.net/~kernel-packages
More help : https://help.launchpad.net/ListHelp