Mount zpool failed to start

i get a disk error after e2fsck and clean start fresh and lxc ls say :slight_smile:Error: Get “http://unix.socket/1.0”: EOF
in lxd --debug --group lxd i found Failed to start the daemon: Failed initializing storage pool “mypool”: Failed to run: zpool import -f -d /var/snap/lxd/common/lxd/disks mypool: cannot import ‘mypool’: no such pool available
i look at the /var/snap/lxd/common/lxd/disks there is no file.
i found my pool under storage-pools but mypool.img is gun. I can’t find it.what happen
Please Help Help

Do you have the e2fsck output?
Sounds like it found your mypool.img to be corrupted and removed it, which would be quite problematic…

Maybe it got placed into lost+found?
If not, hopefully you haven’t done much on the system since that e2fsck and so may be able to use some of the ext data recovery tools to get the img file back.

ZFS should be reasonably tolerant to that file itself having seen some corruption, so running a zpool scrub once it’s found and put back in place should be able to track down any damage.

i found mypool.img in lost+found.
and i replace it under disk i try to run lxc ls (my lxd is not install as snap). there can’t see my lxd.
it’s empty (i have only one lxd on it)

my lxd service is down. i try to restart it error in /var/log/lxd/lxd.log is

t=2020-08-18T12:05:42+0200 lvl=info msg=" - closing socket" socket=/var/lib/lxd/unix.socket
t=2020-08-18T12:05:42+0200 lvl=info msg=“Stopping /dev/lxd handler”
t=2020-08-18T12:05:42+0200 lvl=info msg=" - closing socket" socket=/var/lib/lxd/devlxd/sock
t=2020-08-18T12:05:42+0200 lvl=info msg=“Closing the database”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Stopping REST API handler:”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Stopping /dev/lxd handler”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Stopping REST API handler:”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Stopping /dev/lxd handler”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Unmounting temporary filesystems”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Done unmounting temporary filesystems”
t=2020-08-18T12:05:42+0200 lvl=info msg=“Saving simplestreams cache”
t=2020-08-18T12:05:42+0200 lvl=info msg="Saved simplestreams cache

Do:

  • systemctl stop lxd.socket lxd.service
  • lxd --debug --group lxd

That may show a clearer error. I suspect it’s ZFS failing to import it though.

very strange. systemctl status lxd say lxd is not runnig but ps -ef | grep lxd show lxd is running
lxc ls show my lxd. maybe because i have zfs disk as a mount nfs after restart i need to mount disk but lxd is started before mount and service status show error.