Mailinglist Archive: opensuse-bugs (6588 mails)

< Previous Next >
[Bug 1143725] New: qemu-aarch64-binfmt, from qemu-linux-user, not working (no output)
  • From: bugzilla_noreply@xxxxxxxxxx
  • Date: Wed, 31 Jul 2019 22:53:45 +0000
  • Message-id: <>

Bug ID: 1143725
Summary: qemu-aarch64-binfmt, from qemu-linux-user, not working
(no output)
Classification: openSUSE
Product: openSUSE Tumbleweed
Version: Current
Hardware: x86-64
OS: Other
Status: NEW
Severity: Normal
Priority: P5 - None
Component: Basesystem
Assignee: bnc-team-screening@xxxxxxxxxxxxxxxxxxxxxx
Reporter: dfaggioli@xxxxxxxx
QA Contact: qa-bugs@xxxxxxx
Found By: ---
Blocker: ---

Context: I want to run an ARM64 (aarch64) container on an x86 host. This is
possible using qemu Linux user emulation and Linux binfmt. It is supposed to
work like this:

//Fetching an ARM container on x86 (long story)
$ skopeo --override-arch arm64 copy docker://opensuse/leap

//Install qemu Linux user, and setup binfmt for aarch64
# zypper install qemu-linux-user
$ cp /usr/bin/qemu-aarch64-binfmt .
# echo -1 > /proc/sys/fs/binfmt_misc/qemu-aarch64
# echo

//Build our container
$ cat << EOF > Dockerfile
FROM opensuse-arm64/leap
COPY qemu-aarch64-binfmt /usr/bin/qemu-aarch64-binfmt
docker build -t qemu-leap .

//Now I should be able to run the ARM container, like this:
# docker run -it qemu-leap-aarch64-binfmt /bin/sh

But, basically, nothing happens. No output at all, and I'm definitely not
inside an ARM container. Actually, it appears the container exited:

$ docker ps --all
ea2252caf90a qemu-leap "/bin/sh" 4
seconds ago Exited (255) 3 seconds ago

Now, if I, instead of qemu-aarch64-binfmt, use a qemu-aarch64-static binary
copied from a Debian unstable box I have in my home network, i.e., this one:

# ./qemu-aarch64-static -version
qemu-aarch64 version 3.1.0 (Debian 1:3.1+dfsg-8)

Things work! In fact:

$ docker run -it --rm qemu-leap uname -a
Linux bf12752f6a51 5.1.16-1-default #1 SMP Wed Jul 3 12:37:47 UTC 2019
(2af8a22) aarch64 aarch64 aarch64 GNU/Linux

Note the *aarch64*. Of course, we need to change the aarch64 interpreter file
too, in /proc/sys/fs/binfmt

So, basically, it looks like the procedure is correct, or at least can work.
But our qemu-linux-user packages contain binaries that are not adequate for
being used for this use case.

Things/differences to check:
- QEMU version (the debian stolen from Debian, that makes things works is from
QEMU 3.1.0, while we ship 4.0.0
- our patch queue
- our configuration and compile options

You are receiving this mail because:
You are on the CC list for the bug.
< Previous Next >
List Navigation