← Back to team overview

touch-packages team mailing list archive

[Bug 1441068] Re: lxc-destroy fails on btrfs subvolumes

 

This also occurs for limited user containers, without asking for a btrfs
backing store.  This is more of a problem as the limited user can't
delete (or even detect) the subvolume themselves.

On a standard whole-partition-as-btrfs system, as setup by the installer, this looks like:
ID 257 gen 46021 top level 5 path @
ID 258 gen 46021 top level 5 path @home
...
ID 373 gen 35464 top level 257 path @/var/lib/machines
ID 374 gen 45983 top level 258 path faux/.local/share/lxc/vivid/rootfs/var/lib/machines
ID 395 gen 45995 top level 258 path faux/.local/share/lxc/vivid2/rootfs/var/lib/machines
ID 396 gen 46011 top level 258 path faux/.local/share/lxc/vivid3/rootfs/var/lib/machines
ID 397 gen 46014 top level 258 path faux/.local/share/lxc/vivid4/rootfs/var/lib/machines

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to lxc in Ubuntu.
https://bugs.launchpad.net/bugs/1441068

Title:
  lxc-destroy fails on btrfs subvolumes

Status in lxc package in Ubuntu:
  Triaged

Bug description:
  $ sudo lxc-destroy -n adt-vivid
  [sudo] password for martin: 
  lxc_container: utils.c: _recursive_rmdir_onedev: 147 _recursive_rmdir_onedev: failed to delete /srv/lxc/adt-vivid/rootfs/var/lib
  lxc_container: utils.c: _recursive_rmdir_onedev: 147 _recursive_rmdir_onedev: failed to delete /srv/lxc/adt-vivid/rootfs/var
  lxc_container: utils.c: _recursive_rmdir_onedev: 147 _recursive_rmdir_onedev: failed to delete /srv/lxc/adt-vivid/rootfs
  lxc_container: lxccontainer.c: container_destroy: 2050 Error destroying rootfs for adt-vivid
  Destroying adt-vivid failed

  This is because the container rootfs has a btrfs subvolume:

  ID 557 gen 97073 top level 266 path @srv/lxc/adt-
  vivid/rootfs/var/lib/machines

  After "sudo btrfs subvolume delete /srv/lxc/adt-
  vivid/rootfs/var/lib/machines" I can remove the container.

  ProblemType: Bug
  DistroRelease: Ubuntu 15.04
  Package: lxc 1.1.1-0ubuntu4
  ProcVersionSignature: Ubuntu 3.19.0-12.12-generic 3.19.3
  Uname: Linux 3.19.0-12-generic x86_64
  ApportVersion: 2.17-0ubuntu1
  Architecture: amd64
  CurrentDesktop: Unity
  Date: Tue Apr  7 11:51:51 2015
  EcryptfsInUse: Yes
  SourcePackage: lxc
  UpgradeStatus: No upgrade log present (probably fresh install)
  defaults.conf:
   lxc.network.type = veth
   lxc.network.link = lxcbr0
   lxc.network.flags = up
   lxc.network.hwaddr = 00:16:3e:xx:xx:xx
  lxc.conf: lxc.lxcpath = /srv/lxc

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lxc/+bug/1441068/+subscriptions


Follow ups

References