I'm running Ubuntu 16.04 LTS on a desktop that uses a ZFS on Linux (ZoL) pool. My home directory is encrypted using the built-in encryption setup at install time and has worked great, and ZFS has been running happily.

Then, I did something without thinking. I updated the mountpoint of a handful of ZFS datasets to reside within my encrypted home directory. This initially worked fine, but after a reboot I noticed the mounted directories appear empty (no contents are listed). ZFS still reports these sets as using space, but when I attempt to change the mountpoint I receive a umount failed error and the mountpoint remains unchanged.

I suspect that ZFS is likely mounting prior to ecryptfs. When ecryptfs mounts it 'hides' the ZFS mounts. Ecryptfs has empty directories that match the mount name, but they don't appear to be actual ZFS mounts.

So, I'm curious how to untangle this. Is it possible to force ZFS to start without mounting, and would it let me update the mountpoints in that state? Could I boot to single-user mode, leave the encrypted home folder unmounted and get ZFS running?

1 Answer 1


If you boot in single user mode, and the zpool is not automatically imported, you may be able to import the pool into an alternate path structure via the altroot property during import.

zpool import -R /tmp/zfs <poolname>

This will import the pool with everything being mounted under /tmp/zfs. From there, you should be able to zfs set mountpoint=<newpath> <dataset> for any datasets that need a new mountpoint.

then import pool normally on subsequent boots.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .