[lxc-users] "error: LXD still not running after 5 minutes" - failed lxd.migrate - how to recover?

Tomasz Chmielewski mangoo at wpkg.org
Wed Aug 8 19:33:04 UTC 2018


On 2018-08-08 21:06, Tomasz Chmielewski wrote:
> I've tried to migrate from deb to snap on Ubuntu 18.04.
> 
> Unfortunately, lxd.migrate failed with "error: LXD still not running
> after 5 minutes":

(...)

> Not sure how to recover now? The containers seem intact in 
> /var/lib/lxd/

It seems it's partially migrated with no clear info on how to continue. 
Attempting to do "systemctl start lxd" produces:

Error: failed to open cluster database: failed to ensure schema: schema 
version '9' is more recent than expected '7'


Attempting to start lxd from the snap results in:

# /snap/bin/lxc list
Error: Both native and snap packages are installed on this system
        Run "lxd.migrate" to complete your migration to the snap package



# systemctl status lxd
● lxd.service - LXD - main daemon
    Loaded: loaded (/lib/systemd/system/lxd.service; indirect; vendor 
preset: enabled)
    Active: activating (start-post) (Result: exit-code) since Wed 
2018-08-08 19:28:57 UTC; 9s ago
      Docs: man:lxd(1)
   Process: 6829 ExecStart=/usr/bin/lxd --group lxd 
--logfile=/var/log/lxd/lxd.log (code=exited, status=1/FAILURE)
   Process: 6824 
ExecStartPre=/usr/lib/x86_64-linux-gnu/lxc/lxc-apparmor-load 
(code=exited, status=0/SUCCESS)
  Main PID: 6829 (code=exited, status=1/FAILURE); Control PID: 6831 (lxd)
     Tasks: 8
    CGroup: /system.slice/lxd.service
            └─6831 /usr/lib/lxd/lxd waitready --timeout=600

Aug 08 19:28:57 b1 systemd[1]: Starting LXD - main daemon...
Aug 08 19:28:57 b1 lxd[6829]: lvl=warn msg="AppArmor support has been 
disabled because of lack of kernel support" t=2018-08-08T19:28:57+0000
Aug 08 19:28:57 b1 lxd[6829]: lvl=warn msg="CGroup memory swap 
accounting is disabled, swap limits will be ignored." 
t=2018-08-08T19:28:57+0000
Aug 08 19:28:58 b1 lxd[6829]: lvl=eror msg="Failed to start the daemon: 
failed to open cluster database: failed to ensure schema: schema version 
'9' is more recent than expected '7'" t=2018-08-08T19:28:58+0000
Aug 08 19:28:58 b1 lxd[6829]: Error: failed to open cluster database: 
failed to ensure schema: schema version '9' is more recent than expected 
'7'
Aug 08 19:28:58 b1 systemd[1]: lxd.service: Main process exited, 
code=exited, status=1/FAILURE



# lxd.migrate
=> Connecting to source server
error: Unable to connect to the source LXD: Get http://unix.socket/1.0: 
EOF


# dpkg -l|grep lxd
ii  lxd                                   3.0.1-0ubuntu1~18.04.1         
       amd64        Container hypervisor based on LXC - daemon
ii  lxd-client                            3.0.1-0ubuntu1~18.04.1         
       amd64        Container hypervisor based on LXC - client


# snap list
Name  Version    Rev   Tracking  Publisher  Notes
core  16-2.34.3  5145  stable    canonical  core
lxd   3.3        8011  stable    canonical  -



-- 
Tomasz Chmielewski
https://lxadm.com


More information about the lxc-users mailing list