错误:存储池“默认”在此服务器上不可用(losetup 命令失败)

错误:存储池“默认”在此服务器上不可用(losetup 命令失败)

我无法再启动我的 lxc/lxd 容器。我收到错误:Error: Storage pool "default" unavailable on this server

我在 debian sid 上。

根本问题似乎是命令losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img失败,说 default.img 不存在(但它确实存在)。

查看此终端会话:

root@debian-pocket3:~# lxc list
+----------------------+---------+------+------+-----------+-----------+
|         NAME         |  STATE  | IPV4 | IPV6 |   TYPE    | SNAPSHOTS |
+----------------------+---------+------+------+-----------+-----------+
| SiteWebACL           | STOPPED |      |      | CONTAINER | 0         |
+----------------------+---------+------+------+-----------+-----------+
| sitesVitrinesOne-dev | STOPPED |      |      | CONTAINER | 0         |
+----------------------+---------+------+------+-----------+-----------+
| sitesVitrinesTwo-dev | STOPPED |      |      | CONTAINER | 0         |
+----------------------+---------+------+------+-----------+-----------+
| testWoocommerce-dev  | STOPPED |      |      | CONTAINER | 0         |
+----------------------+---------+------+------+-----------+-----------+


root@mydebianbox:~# lxc start sitesVitrinesTwo-dev 
Error: Storage pool "default" unavailable on this server

root@mydebianbox:~# lxc storage info default
info:
  description: ""
  driver: btrfs
  name: default
  space used: 40.46GiB
  total space: 133.56GiB
used by:
  instances:
  - SiteWebACL
  - sitesVitrinesOne-dev
  - sitesVitrinesTwo-dev
  - testWoocommerce-dev
  profiles:
  - default

root@mydebianbox:~# cat /var/snap/lxd/common/lxd/logs/lxd.log
time="2023-07-23T17:57:19+02:00" level=warning msg=" - Couldn't find the CGroup network priority controller, network priority will be ignored"
time="2023-07-23T17:57:21+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T17:57:21+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=sitesVitrinesTwo-dev instanceType=container project=default
time="2023-07-23T17:57:21+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=testWoocommerce-dev instanceType=container project=default
time="2023-07-23T17:57:21+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=sitesVitrinesOne-dev instanceType=container project=default
time="2023-07-23T17:57:21+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=SiteWebACL instanceType=container project=default
time="2023-07-23T17:58:21+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T17:59:22+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T18:00:22+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T18:01:22+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T18:02:23+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default
time="2023-07-23T18:03:16+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=testWoocommerce-dev instanceType=container project=default
time="2023-07-23T18:03:16+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=sitesVitrinesOne-dev instanceType=container project=default
time="2023-07-23T18:03:16+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=sitesVitrinesTwo-dev instanceType=container project=default
time="2023-07-23T18:03:16+02:00" level=error msg="Error getting disk usage" err="Storage pool is unavailable on this server" instance=SiteWebACL instanceType=container project=default
time="2023-07-23T18:03:23+02:00" level=error msg="Failed mounting storage pool" err="Failed to run: losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img: exit status 1 (losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory)" pool=default

root@mydebianbox:~# ls -lh /var/snap/lxd/common/lxd/disks/default.img 
-rw------- 1 root root 14G 21 juil. 10:30 /var/snap/lxd/common/lxd/disks/default.img

root@mydebianbox:~# losetup --find --nooverlap --direct-io=on --show /var/snap/lxd/common/lxd/disks/default.img
losetup: /var/snap/lxd/common/lxd/disks/default.img: failed to set up loop device: No such file or directory

我该如何进一步调试和/或解决问题?

相关内容