Package: qemu-user
Version: 1:10.0.8+ds-0+deb13u1+b2
Severity: important
X-Debbugs-Cc: [email protected]
Dear Maintainer,
* What led up to the situation?
I wanted to install a cross-compile/emulation setup for s390x (the
only(?) big-endian arch supported by debian).
* What exactly did you do (or not do) that was effective (or
ineffective)?
I installed the s390x cross compiler, apt-get install gcc-s390x-linux-gnu.
I enabled s390x as a foreign arch, dpkg --add-foreign-architectore
s390x, and ran apt-get update. (My intention was to enable
installation of s390x library dev packages, e.g., apt-get install
nettle-dev:s390x. But I haven't been able to actually do that install,
due to what looked like version conflicts with my native libc, which I
haven't investigated).
Next, I wanted qemu-user. Just running apt-get install qemu-user also
installs the recommended qemu-user-binfmt package. Since I didn't want
to get the binfmt magic, I instead ran apt-get install qemu-user
qemu-user-binfmt- (note trailing -). Then apt-get decided to install
the additional package qemu-user-binfmt:s390x, and I accepted that
and pressed ENTER without realizing the bad consequences.
* What was the outcome of this action?
I could no longer execute *any* native (x86_64) binaries, no ls, no
dpkg, no apt-get... Everything failed, and as far as I understand this
broken state, my shell got a ENOEXEC error from the exec syscall. My
computer was closed to bricked. (Luckily, I still had an open root
bash shell, and I could use the *builtin* printf command like printf
"" > /usr/lib/binfmt.d/qemu-x86_64.conf, reboot using the power
button, and get back to a working state where I could run apt-get
remove qemu-user-binfmt:s390x).
* What outcome did you expect instead?
Execution of native binaries unaffected. s390x binaries executable
only by invoking qemu-s390x explicitly.
-- System Information:
Debian Release: 13.5
APT prefers stable-updates
APT policy: (990, 'stable-updates'), (990, 'stable-security'), (990,
'stable'), (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: s390x
Kernel: Linux 6.12.88+deb13-amd64 (SMP w/16 CPU threads; PREEMPT)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8),
LANGUAGE=en_US:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
qemu-user depends on no packages.
Versions of packages qemu-user recommends:
pn qemu-user-binfmt <none>
qemu-user suggests no packages.
-- no debconf information