Forum › Forums › Official Releases › antiX-21/22 “Grup Yorum” › [solved] docker on antiX 21 live USB/CD: failed to start daemon
Tagged: docker
- This topic has 3 replies, 2 voices, and was last updated Jan 2-9:38 am by rayluo.
-
AuthorPosts
-
December 29, 2021 at 5:12 am #74012Member
rayluo
Hi antiX community,
Are there any docker users here? Today I noticed that, the docker daemon was unable to start on my antiX 21 environment. I wonder whether any docker users here can share your experience on docker + antiX21.
The steps below are how I encountered (and reproduced) the issue on my antiX 21 live CD/USB. I believe I used the same steps at 1+ year ago when I was using antiX 19.3 and it was successful at that time.
1. Start afresh, by booting a VM with the official antiX 21 full iso.
2. Follow step 2 & 3 here in the official Docker installation guide on “Set up the repository”. (Its step 1 seems unnecessary.)
3. I did NOT continue with the “Install Docker Engine” steps from the official docker installation guide (shall I?). I switch to use antiX’s “Synaptic Package Manager”, “Reload” its content, and then I can search “docker-ce” and install it successfully.
4. After the installation, the docker daemon is – I don’t quite remember – either already automatically running in the background, or your can simply do “sudo service docker start” to start it.
5. And then you can use “docker” command the way it should be.
6. At this point, I want to make an ISO snapshot with my current system. (FWIW, I did add 3 more minor CLI software, but they shouldn’t make a difference to the docker behaviors.)
7. When I reboot my VM with the new ISO CD, everything else works as expected, but the docker daemon is not running. Manually runs “sudo service docker start” or “sudo dockerd”, and the result is the same:... failed to start daemon: rename /var/lib/docker/runtimes /var/lib/docker/runtimes-old: invalid cross-device linkSearching online, some info said it was relative to the use of the overlay filesystem. That hypothesis perhaps makes sense, as antiX’s live CD or live USB does use overlay filesystem. But the thing is, I remember that I could to the same step 1-7 successfully when I was using antix 19.3. I currently still have such an antiX 19.3 snapshot ISO, whose docker works.
I hope some other docker users here can shed some light here.
Regards,
Ray Luo- This topic was modified 1 year, 4 months ago by anticapitalista. Reason: solved
December 29, 2021 at 11:41 pm #74079Anonymous
::I am not using docker. Yes, seems due to overlayfs choking when attempting metacopy.
In the github issue page that you linked, did you try this solution:aquaminer commented on Dec 11, 2018
Solution: https://gist.github.com/Francesco149/ce376cd83d42774ed39d34816b9e21dbI could to the same step 1-7 successfully when I was using antix 19.3
Success was probably specific to the exact/specific kernel in use (rather than the generic observation “antiX version 19.3)
related reading found via websearch:
https://bbs.archlinux.org/viewtopic.php?id=241866
https://github.com/docker/for-linux/issues/480December 30, 2021 at 3:15 am #74091Member
rayluo
::Thanks for chiming in, @skidoo.
did you try this solution:
aquaminer commented on Dec 11, 2018
Solution: https://gist.github.com/Francesco149/ce376cd83d42774ed39d34816b9e21dbMost – if not all – the solutions out there were essentially the same. They suggested to somehow disable the metacopy parameter. So, I tried adding “quiet overlay.metacopy=N” as boot time parameter (which was inspired by this message, and it is easy to do in antiX), however it makes no difference. I also tried that particular command “echo N | sudo tee /sys/module/overlay/parameters/metacopy” after antiX boots, but strangely it failed with a permission denied, even when/if I am using root account.
Success was probably specific to the exact/specific kernel in use (rather than the generic observation “antiX version 19.3)
Maybe the issue is kernel specific, or maybe not. I happen to be that kind of antiX user that do not change its original kernel. In that sense, it feels like an antiX 21 regression that the docker works in antiX 19.3 (shipped with kernel 4.9.235) but fails in antiX 21 (shipped with both – and can be selected between – “legacy kernel” 4.9.0-279 and “modern kernel” 5.10.57).
January 2, 2022 at 9:38 am #74411Member
rayluo
::After many trial and error, I figured out how to bypass that confusing “failed to start daemon: rename /var/lib/docker/runtimes /var/lib/docker/runtimes-old: invalid cross-device link” error. Just configure docker to use a different directory to store its data, hinted by this official document, and this github message. The following example is optimized for my usage of Live USB, but you can get the idea of how to customize it, when necessary.
$ cat /etc/docker/daemon.json {"data-root": "/home/demo/Live-usb-storage/docker"}P.S.: Moderator please help add a “[Solved]” prefix to this thread’s subject. It seems I am not able to do it by myself.
-
AuthorPosts
- You must be logged in to reply to this topic.