You are not logged in.

#1 2020-09-16 19:04:02

positronik
Member
Registered: 2016-02-08
Posts: 94

LXC overlay does not start after migration

Hello,

I have some lxc containers setup with overlayfs as per wiki instruction.
The folder where they are located is on an HDD and I would like to migrate it to an SDD.
I simply did

rsync -aAXHv /var/lib/lxc/ /mnt

where /mnt is the new partition that'll be later mounted as /var/lib/lxc.

Now, when I remount /mnt in /var/lib/lxc the overlay container does not start anymore.

The logfile with logpriority DEBUG is here http://sprunge.us/BAU8Io

Same also after a reboot.

Offline

#2 2020-09-17 05:59:54

solskog
Member
Registered: 2020-09-05
Posts: 414

Re: LXC overlay does not start after migration

I don't known how you setup container nor your overlay command.

From: https://wiki.archlinux.org/index.php/Li … g_programs
Note: overlayfs for unprivileged containers is not supported in the current mainline Arch Linux kernel due to security considerations.

Offline

#3 2020-09-17 07:56:36

Khere
Member
From: Italy
Registered: 2020-03-04
Posts: 169

Re: LXC overlay does not start after migration

https://stackoverflow.com/questions/234 … ontainers/

Last edited by Khere (2020-09-17 07:59:06)


Fan of Giorgio Moroder & Mohammad Ammax enemy

Offline

#4 2020-09-17 16:40:47

positronik
Member
Registered: 2016-02-08
Posts: 94

Re: LXC overlay does not start after migration

@solskog I set it up as per wiki instructions. It's unprivileged.

@khere rsync is equivalent to the procedure you posted. I have other containers that are not overlay (for instance the base one) that work after the rsync.

It seems to have something to do with the mounting as can be seen from the log. In fact mounting the overlayfs gives a Stale File Handle error.

EDIT: I solved the issue in quite an unorthodox way, so if anyone has better ideas please do not hesitate to enlighten me.
I basically destroyed the overlay container, recreated it with lxc-copy and then

cp -pr /mnt/container/overlay/delta /var/lib/lxc/container/overlay/delta

Now the container starts and seem to be fine.

Last edited by positronik (2020-09-17 18:58:35)

Offline

Board footer

Powered by FluxBB