I am using LXD to manage Linux containers, and deleted a running container using lxd delete --force test. LXD is using a ZFS pool. The container was snapshoted periodically, is it possible to recover a container snapshot? Output from zpool history

2018-06-04.00:15:41 zfs destroy -r lxd/containers/test@snapshot-snap720
2018-06-04.00:15:42 zfs destroy -r lxd/containers/test@snapshot-snap721
2018-06-04.00:15:42 zfs destroy -r lxd/containers/test@snapshot-snap722
2018-06-04.00:15:43 zfs destroy -r lxd/containers/test@snapshot-snap723
2018-06-04.00:15:43 zfs destroy -r lxd/containers/test@snapshot-snap724
2018-06-04.00:15:43 zfs destroy -r lxd/containers/test@snapshot-snap725
2018-06-04.00:15:44 zfs destroy -r lxd/containers/test@snapshot-snap726
2018-06-04.00:15:44 zfs destroy -r lxd/containers/test@snapshot-snap727
2018-06-04.00:15:45 zfs destroy -r lxd/containers/test@snapshot-snap728
2018-06-04.00:15:45 zfs destroy -r lxd/containers/test@snapshot-snap729
2018-06-04.00:15:46 zfs rename -r lxd/containers/test@snapshot-snap730 lxd/containers/test@copy-a62a8fe6-863f-441c-86cc-62721f0a2f41
2018-06-04.00:15:46 zfs set mountpoint=none lxd/containers/test
2018-06-04.00:15:48 zfs rename -p lxd/containers/test lxd/deleted/containers/87190c6f-09d0-4b27-8a0e-9cd9c1e53728
2018-06-04.00:15:56 zfs destroy -r lxd/snapshots/test

I guess from the output that the latest snapshot was not destroyed, and only renamed, same for the container, is there any way to recover them?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.