Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run image with older architecture arm v6 (docker engine v24.0.7) #47026

Open
aggo15 opened this issue Jan 5, 2024 · 3 comments
Open
Labels
kind/bug Bugs are bugs. The cause may or may not be known at triage time so debugging may be needed. status/more-info-needed status/0-triage version/24.0

Comments

@aggo15
Copy link

aggo15 commented Jan 5, 2024

Description

Failed to run image built with arm v6 architecture. No issue running image built with arm64 v8 architecture. Encounter error message below when attempt to start the container:

bash: error while loading shared libraries: libtinfo.so.6: ELF load command address/offset not page-aligned

Reproduce

Environment: Raspberry Pi 5 bookworm os 64bit

cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

Execute docker run -it --rm --entrypoint bash balenalib/raspberry-pi-debian:bookworm and the error below will appear.

bash: error while loading shared libraries: libtinfo.so.6: ELF load command address/offset not page-aligned

Expected behavior

After execute docker run -it --rm --entrypoint bash balenalib/raspberry-pi-debian:bookworm, we should be able to enter the container shell.

pi@raspberry:/ $ docker run -it --rm --entrypoint bash balenalib/raspberry-pi-debian:bookworm
root@5a962c34caa3:/#

docker version

Client: Docker Engine - Community
 Version:           24.0.7
 API version:       1.43
 Go version:        go1.20.10
 Git commit:        afdd53b
 Built:             Thu Oct 26 09:08:15 2023
 OS/Arch:           linux/arm64
 Context:           default

Server: Docker Engine - Community
 Engine:
  Version:          24.0.7
  API version:      1.43 (minimum version 1.12)
  Go version:       go1.20.10
  Git commit:       311b9ff
  Built:            Thu Oct 26 09:08:15 2023
  OS/Arch:          linux/arm64
  Experimental:     false
 containerd:
  Version:          1.6.26
  GitCommit:        3dd1e886e55dd695541fdcd67420c2888645a495
 runc:
  Version:          1.1.10
  GitCommit:        v1.1.10-0-g18a0cb0
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

docker info

Client: Docker Engine - Community
 Version:    24.0.7
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.11.2
    Path:     /usr/libexec/docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.21.0
    Path:     /usr/libexec/docker/cli-plugins/docker-compose

Server:
 Containers: 1
  Running: 1
  Paused: 0
  Stopped: 0
 Images: 4
 Server Version: 24.0.7
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 1
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 3dd1e886e55dd695541fdcd67420c2888645a495
 runc version: v1.1.10-0-g18a0cb0
 init version: de40ad0
 Security Options:
  seccomp
   Profile: builtin
 Kernel Version: 6.1.0-rpi7-rpi-2712
 Operating System: Debian GNU/Linux 12 (bookworm)
 OSType: linux
 Architecture: aarch64
 CPUs: 4
 Total Memory: 7.861GiB
 Name: raspberrypi
 ID: d1e34987-e19b-4b68-ba91-717422f9ce9b
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Experimental: false
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false

Additional Info

No response

@aggo15 aggo15 added kind/bug Bugs are bugs. The cause may or may not be known at triage time so debugging may be needed. status/0-triage labels Jan 5, 2024
@thaJeztah
Copy link
Member

From a quick glance, this seems to be an issue with libtinfo inside the container.

I tried reproducing this on my m1 (arm64) mac with Docker Desktop, but it looks to be working there, however, it's possible that QEMU is used there. It could be something to seccomp; could you try if it works if you run the container with seccomp disabled ("unconfined")?

docker run -it --rm --entrypoint bash --security-opt seccomp=unconfined balenalib/raspberry-pi-debian:bookworm

@aggo15
Copy link
Author

aggo15 commented Jan 5, 2024

Hi @thaJeztah , I'm getting the same error message as reported in the original post.

pi@raspberry:~ $ docker run -it --rm --entrypoint bash --security-opt seccomp=unconfined balenalib/raspberry-pi-debian:bookworm
bash: error while loading shared libraries: libtinfo.so.6: ELF load command address/offset not page-aligned

@aggo15
Copy link
Author

aggo15 commented Apr 8, 2024

I was able to find the workaround by changing the Raspberry Pi 5 config.txt by adding a line kernel=kernel8.img to it. Source that suggesting the workaround is here. Not sure if this issue is relevant to moby or something you guys can fix. If not you may close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Bugs are bugs. The cause may or may not be known at triage time so debugging may be needed. status/more-info-needed status/0-triage version/24.0
Projects
None yet
Development

No branches or pull requests

2 participants