How can I change the filesystem name on a ZFS pool?

(James Pond) #1

Hey :wave:t3:, everyone,

The title sucks as I am not completely sure I understand everything yet. Sorry about that.

Is there a way to change the output of df -h inside a container to be zfspoolname/SOMETHINGELSE/containername instead of the default /zfspoolname/containers/containername?

My ZFS pool is called “TARDIS”, so the default output for df -h inside the container called gitgitdev is:

root@gitgitdev:~# df -h
Filesystem                   Size  Used Avail Use% Mounted on
tardis/containers/gitgitdev  103G  341M  103G   1% /

Would it be possible to change it to something like this instead?

root@gitgitdev:~# df -h
Filesystem                   Size  Used Avail Use% Mounted on
tardis/space-loop/gitgitdev  103G  341M  103G   1% /

Notice the “space-loop” name after “tardis”. This is purely cosmetic and serves no practical purpose, but I would still like to know if it is possible :man_shrugging:t2:

Thanks in advance! :upside_down_face:

(Stéphane Graber) #2

No, this isn’t possible. LXD uses standard names on all storage backends. While it would be technically possible to make this configurable on a per-pool basis, it’d be quite work intensive to go and allow for that customization everywhere and would make support significantly harder for us as we would need to ask a few extra questions before we can tell people where to go look for their data.

(James Pond) #3

Hey, @stgraber,

Thank you for your reply! I figured that would not work, but asking does not hurt. That was purely cosmetic and an internal joke anyway, so not having it is not a problem.

Thanks again!