Package: zfsutils-linux Version: 2.0.3-9 |Severity: important|
Hi, Currently, creating a ZFS dataset with mountpoint=legacy and adding it to /etc/fstab as auto causes the system to hang at boot because the mount is attempted before the pool has been imported or the ZFS module loaded. How to reproduce: apt install zfsutils-linux modprobe zfs zpool create tank sdb zfs set mountpoint=legacy tank echo "tank /mnt zfs defaults 0 0" >> /etc/fstab reboot The boot process will hang because /mnt did not mount properly. "journalctl -b -u mnt.mount" shows the following (I don't know why the dates aren't sorted): Jan 11 11:41:16 localhost mount[702]: The ZFS modules are not loaded. Jan 11 11:41:16 localhost mount[702]: Try running '/sbin/modprobe zfs' as root to load them. Jan 11 11:41:13 localhost systemd[1]: Mounting /mnt... Jan 11 11:41:14 localhost systemd[1]: mnt.mount: Mount process exited, code=exited, status=2/INVALIDARGUMENT Jan 11 11:41:14 localhost systemd[1]: mnt.mount: Failed with result 'exit-code'. Jan 11 11:41:14 localhost systemd[1]: Failed to mount /mnt. "journalctl -b -u zfs-load-module.service" shows that the module was loaded afterwards: Jan 11 11:41:19 localhost systemd[1]: Starting Install ZFS kernel module... Jan 11 11:41:19 localhost systemd[1]: Finished Install ZFS kernel module. The same goes for "journalctl -b -u zfs-import-cache.service": Jan 11 11:41:19 localhost systemd[1]: Starting Import ZFS pools by cache file... Jan 11 11:41:19 localhost systemd[1]: Finished Import ZFS pools by cache file. I worked around the problem by making sure the zfs-import.target (used by zfs-import-{cache,scan}.service) is active before mounts are attempted. Contents of /etc/systemd/system/zfs-import.target.d/override.conf [Unit] Before=local-fs-pre.target Should Debian edit /lib/systemd/system/zfs-import.target to include this? Should I report this bug upstream? Are there any dependency loop risks I might have overlooked? Kind regards, Louis
OpenPGP_signature
Description: OpenPGP digital signature