(Snap) LXD Resize default BTRFS storage pool

Update : for LXD on snap when using default BTRFS storage pool :

  • Enter any container and execute df -h | grep loop and you can see the loop
  • Stop containers
  • mkdir /mnt/loop{n°}
  • mount /dev/loop{n°} /mnt/loop{n°}
  • truncate -s +{size}G /var/snap/lxd/common/lxd/disks/default.img
  • reboot
  • Check if all containers are stoped if not stop them
  • btrfs filesystem resize max /var/snap/lxd/common/mntns/var/snap/lxd/common/lxd/storage-pools/default
2 Likes