[lxc-users] Storage pool grew larger than the host disc

Yakov exebook at gmail.com
Sun Mar 29 19:39:57 UTC 2020


My LXD was configured by me to be 100GB during install but after a week or
two it grew to take the entire host disc:

stat /mnt/var/snap/lxd/common/lxd/disks/default.img
  File: /mnt/var/snap/lxd/common/lxd/disks/default.img
  Size: 256000000000    Blocks: 441883848  IO Block: 4096   regular file

The data inside the container is actually only 30GB.

Now even the host machine cannot boot because there is no space left on the
device.

# df .
Filesystem     1K-blocks      Used Available Use% Mounted on
/dev/md2       227923708 225440664         0 100% /mnt

default.img seems to be ZFS because:

mount -o loop /mnt/var/snap/lxd/common/lxd/disks/default.img /mnt1
mount: /mnt1: unknown filesystem type 'zfs_member'.

I read entire mans for zfs and zpool and googled for hours, and browser LXD
manual as well, but I can't find any way to fix the problem. I need to
shrink the default.img some how. Please help!

Currently I can only access the host machine through the Rescue boot on
Hetzner. So I can use zfs/zpool more or less with zfs-fuse.

Our production system is down, sigh.

Yash
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20200330/41112af3/attachment.htm>


More information about the lxc-users mailing list