[SOLVED] Issue with Docker since kernel upgrade from 5.4.78-pve to 5.4.98-pve

kenji

Member
Feb 24, 2021
13
6
8
40
Having a unprivileged lxc container running docker container fine with 5.4.78-pve kernel

Made the kernel upgrade, docker container can't start after, here is the error :

Code:
docker run hello-world
docker: Error response from daemon: OCI runtime create failed: container_linux.go:370: starting container process caused: process_linux.go:326: applying cgroup configuration for process caused: could not execute `systemctl --user --no-pager show-environment`, output="Failed to connect to bus: $DBUS_SESSION_BUS_ADDRESS and $XDG_RUNTIME_DIR not defined\n": exit status 1: unknown.
ERRO[0000] error waiting for container: context canceled

Of course no changes were made to the lxc/"id".conf:

Code:
arch: amd64
features: keyctl=1,nesting=1
hostname: REDACTED
memory: 4096
net0: name=eth0,bridge=vmbr0,gw=REDACTED,hwaddr=REDACTED,ip=REDACTED,type=veth
onboot: 1
ostype: debian
rootfs: zfs-storage:subvol-1001-disk-0,size=16G
swap: 512
unprivileged: 1
 
Last edited:
hmm.... tried to create another container

Code:
# cat /etc/pve/lxc/1094.conf
#test-docker
arch: amd64
features: nesting=1
hostname: test-docker
memory: 4096
net0: name=eth0,bridge=vmbr0,gw=10.1.0.1,hwaddr=02:37:82:7c:95:78,ip=10.1.0.94/24,type=veth
onboot: 1
ostype: debian
rootfs: zfs-storage:subvol-1094-disk-0,size=16G
swap: 512
unprivileged: 1

installed docker on it

Code:
apt-get install apt-transport-https ca-certificates curl gnupg2 software-properties-common
curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add -
apt-key fingerprint 0EBFCD88
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable"
apt-get update
apt-get install docker-ce docker-compose

and it worked...

Code:
root@test-docker:~# docker run hello-world
Unable to find image 'hello-world:latest' locally
latest: Pulling from library/hello-world
0e03bdcc26d7: Pull complete
Digest: sha256:95ddb6c31407e84e91a986b004aee40975cb0bda14b5949f6faac5d2deadb4b9
Status: Downloaded newer image for hello-world:latest

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
1. The Docker client contacted the Docker daemon.
2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
    (amd64)
3. The Docker daemon created a new container from that image which runs the
    executable that produces the output you are currently reading.
4. The Docker daemon streamed that output to the Docker client, which sent it
    to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
$ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
https://hub.docker.com/

For more examples and ideas, visit:
https://docs.docker.com/get-started/

root@test-docker:~# docker container ls
CONTAINER ID   IMAGE     COMMAND   CREATED   STATUS    PORTS     NAMES
root@test-docker:~# docker container ls -a
CONTAINER ID   IMAGE         COMMAND    CREATED          STATUS                      PORTS     NAMES
681078ce62dd   hello-world   "/hello"   36 seconds ago   Exited (0) 36 seconds ago             cool_snyder

the 7 errors game start :D
 
ended up stopping the container, renaming the zfs FS, destroying the container and creating it again, copying /var/lib/docker from old FS to the new FS, and it works...
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!