Discussion:
LXD and ZFS disappeared container mount points
(too old to reply)
tapczan
2016-05-30 14:11:56 UTC
Permalink
Hi

When I create LXD container on ZFS backend I see:

# df
lxd/containers/c1
30191104 190080 30001024 1% /var/lib/lxd/containers/c1.zfs

# mount
lxd/containers/c1 on /var/lib/lxd/containers/c1.zfs type zfs
(rw,relatime,xattr,noacl)

# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is a mountpoint

# zfs list
lxd/containers/c1
2.39M 28.6G 186M /var/lib/lxd/containers/c1.zfs

Everything ok.

But after some time this mount point disappears from df, mount output:

# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is not a mountpoint

What is interesting container is still working and 'zfs list' is
showing that '/var/lib/lxd/containers/c1.zfs' is mounted.
I see this behaviour on multiple hosts.

Has anybody some clue why is it happening?
Tamas Papp
2016-05-30 14:15:49 UTC
Permalink
Post by tapczan
Hi
# df
lxd/containers/c1
30191104 190080 30001024 1% /var/lib/lxd/containers/c1.zfs
# mount
lxd/containers/c1 on /var/lib/lxd/containers/c1.zfs type zfs
(rw,relatime,xattr,noacl)
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is a mountpoint
# zfs list
lxd/containers/c1
2.39M 28.6G 186M /var/lib/lxd/containers/c1.zfs
Everything ok.
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is not a mountpoint
What is interesting container is still working and 'zfs list' is
showing that '/var/lib/lxd/containers/c1.zfs' is mounted.
I see this behaviour on multiple hosts.
Has anybody some clue why is it happening?
I also experience this but still don't have a reproducer.
It somehow must be related to stopping instanced.


tamas
Jamie Brown
2016-05-31 10:42:34 UTC
Permalink
Jut experienced the same problem today;

Ubuntu 16.04 (4.4.0-22-generic)
LXD 2.0.0

zfs list
rpool/containers/cassandra … /var/lib/lxd/containers/cassandra.zfs

df -h
Missing

Container starup error;
lxc 20160531103027.198 ERROR lxc_conf - conf.c:mount_rootfs:807 - No such file or directory - failed to get real path for '/var/lib/lxd/containers/cassandra/rootfs'
Post by Tamas Papp
Post by tapczan
Hi
# df
lxd/containers/c1
30191104 190080 30001024 1% /var/lib/lxd/containers/c1.zfs
# mount
lxd/containers/c1 on /var/lib/lxd/containers/c1.zfs type zfs
(rw,relatime,xattr,noacl)
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is a mountpoint
# zfs list
lxd/containers/c1
2.39M 28.6G 186M /var/lib/lxd/containers/c1.zfs
Everything ok.
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is not a mountpoint
What is interesting container is still working and 'zfs list' is
showing that '/var/lib/lxd/containers/c1.zfs' is mounted.
I see this behaviour on multiple hosts.
Has anybody some clue why is it happening?
I also experience this but still don't have a reproducer.
It somehow must be related to stopping instanced.
tamas
_______________________________________________
lxc-users mailing list
http://lists.linuxcontainers.org/listinfo/lxc-users
Stéphane Graber
2016-05-31 15:27:55 UTC
Permalink
Run: zfs mount -a

That should fix it.

It looks like things occasionaly unmount themselves with zfs and we're
not quite sure why.

I have sent a patch upstream which will make it to LXD 2.0.3 and just
does a "zfs mount" when needed...
Post by Jamie Brown
Jut experienced the same problem today;
Ubuntu 16.04 (4.4.0-22-generic)
LXD 2.0.0
zfs list
rpool/containers/cassandra 
 /var/lib/lxd/containers/cassandra.zfs
df -h
Missing
Container starup error;
lxc 20160531103027.198 ERROR lxc_conf - conf.c:mount_rootfs:807 - No such file or directory - failed to get real path for '/var/lib/lxd/containers/cassandra/rootfs'
Post by Tamas Papp
Post by tapczan
Hi
# df
lxd/containers/c1
30191104 190080 30001024 1% /var/lib/lxd/containers/c1.zfs
# mount
lxd/containers/c1 on /var/lib/lxd/containers/c1.zfs type zfs
(rw,relatime,xattr,noacl)
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is a mountpoint
# zfs list
lxd/containers/c1
2.39M 28.6G 186M /var/lib/lxd/containers/c1.zfs
Everything ok.
# mountpoint /var/lib/lxd/containers/c1.zfs
/var/lib/lxd/containers/c1.zfs is not a mountpoint
What is interesting container is still working and 'zfs list' is
showing that '/var/lib/lxd/containers/c1.zfs' is mounted.
I see this behaviour on multiple hosts.
Has anybody some clue why is it happening?
I also experience this but still don't have a reproducer.
It somehow must be related to stopping instanced.
tamas
_______________________________________________
lxc-users mailing list
http://lists.linuxcontainers.org/listinfo/lxc-users
_______________________________________________
lxc-users mailing list
http://lists.linuxcontainers.org/listinfo/lxc-users
--
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
tapczan
2016-05-31 19:34:23 UTC
Permalink
Post by Stéphane Graber
I have sent a patch upstream which will make it to LXD 2.0.3 and just
does a "zfs mount" when needed...
Thanks for info.
Is there any possibility to download nightly builds of lxd to test
2.0.3 with your fix?
Stéphane Graber
2016-05-31 19:38:08 UTC
Permalink
Post by tapczan
Post by Stéphane Graber
I have sent a patch upstream which will make it to LXD 2.0.3 and just
does a "zfs mount" when needed...
Thanks for info.
Is there any possibility to download nightly builds of lxd to test
2.0.3 with your fix?
Not yet, no. We haven't yet hooked up package builds with our Jenkins
for LXD (just for LXC).
--
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
Loading...