From 7a0abea25112eb3227c68c84a45cb657b85ef34f Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Wed, 3 Feb 2021 01:31:57 +0100 Subject: [PATCH] Disable also swapfiles in /var/lib/lxd (in setups where lxd ain't installed using snap) --- lib/lxc.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/lxc.sh b/lib/lxc.sh index a143d77..6de0915 100644 --- a/lib/lxc.sh +++ b/lib/lxc.sh @@ -102,6 +102,7 @@ LXC_STOP () { LXC_RESET () { timeout 30 lxc stop --timeout 15 $LXC_NAME --force 2>/dev/null swapoff /var/snap/lxd/common/lxd/containers/$LXC_NAME/rootfs/swap_* 2>/dev/null + swapoff /var/lib/lxd/containers/$LXC_NAME/rootfs/swap_* 2>/dev/null lxc delete $LXC_NAME --force 2>/dev/null }