diff --git a/devstack/plugin.sh b/devstack/plugin.sh index cd37314f..9bae2387 100755 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -133,7 +133,11 @@ function shutdown_nova-lxd() { function cleanup_nova-lxd() { # Cleanup the service. if [ "$LXD_BACKEND_DRIVER" == "zfs" ]; then - sudo zpool destroy ${LXD_ZFS_ZPOOL} + pool=`lxc profile device get default root pool 2>> /dev/null || :` + if [ "$pool" == "$LXD_ZFS_ZPOOL" ]; then + sudo lxc profile device remove default root + sudo lxc storage delete $LXD_ZFS_ZPOOL + fi fi }