运行DPKG时QEMU untured Target Signal 11-配置Libc-bin
在我的主机计算机上运行Docker容器(ARM64V8
/aarch64
)时(AMD64
)容器,它给了我以下错误:
[ cut for size, full log at https://pastebin.com/7ZtvqZsD ]
#6 18.65 Setting up libc-bin (2.31-13+deb11u3) ...
#6 18.92 qemu: uncaught target signal 11 (Segmentation fault) - core dumped
#6 19.03 Segmentation fault (core dumped)
#6 19.06 qemu: uncaught target signal 11 (Segmentation fault) - core dumped
#6 19.15 Segmentation fault (core dumped)
#6 19.15 dpkg: error processing package libc-bin (--configure):
#6 19.15 installed libc-bin package post-installation script subprocess returned error exit status 139
#6 19.20 Errors were encountered while processing:
#6 19.20 libc-bin
#6 19.31 E: Sub-process /usr/bin/dpkg returned an error code (1)
------
executor failed running [/bin/sh -c apt-get -y reinstall libc-bin]: exit code: 100
最小可重复的示例
FROM arm64v8/debian
RUN apt-get -y update
RUN apt-get -y reinstall libc-bin
版本
$ qemu-system-aarch64 --version # installed via pacman -S qemu-full
QEMU emulator version 7.0.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developer
$ qemu-system-arm --version # installed via pacman -S qemu-full
QEMU emulator version 7.0.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developer
$ docker --version
Docker version 20.10.17, build 100c70180f
## Binfmt extensions installed with
docker run --privileged --rm tonistiigi/binfmt --install all &
$ uname -a
Linux <hostname> 5.18.7-zen1-1-zen #1 ZEN SMP PREEMPT_DYNAMIC Sat, 25 Jun 2022 20:22:03 +0000 x86_64 GNU/Linux
## OS
Arch linux
先前阅读
(又名请不要将我的问题标记为这些重复项,它与它们不同)
qemu:uck offact的目标信号11(分段故障) - 核心容器中的核心
这些答案对我不起作用,我正在运行Arch Linux存储库中的最新QEMU,arm64v8/debian
并不是我所能透露的,我没有使用过的弃用容器图像Docker-for-Mac。另外,这个问题将相反的方向(AMD64
arm64
上的容器)。
qemu:未透露的目标信号11(分段错误)
问题不是源于git,因此这个问题的答案无济于事。
qemu-arm qemu> qemu-arm qemu:uckaut target Signal Signal 11(分段故障) - 核心倾倒
也不有用,我尝试使用Qemu-user静态v7.0.0(编译和-bin)也没有解决我的问题。不确定TCG解释器是什么,所以这可能是问题,但是我对Qemu不太熟悉,无法知道如何“禁用TCG解释器”。
qemu und offfect und offfect目标信号11分割错误 - 唯一在ARM64构建
上 我的内核是5.18.7-Zen1-1- Zen,它比答案所建议的5.10.0-8还要新,并且是撰写时在Arch Linux存储库上可用的最新信息。
qemu:qemu:nuckauth target信号11(分割错误) - 核心倾倒,试图返回结构
答案与我不使用的C相关。
目标
我的最终目标是使用Multistap
构建一个根文件系统,以最终放在ARM64设备上,但是此问题使我无法做任何事情,因为运行dpkg -configure- configure-
是必须从一开始就必须运行的步骤之一。
When running a docker container (arm64v8
/aarch64
) on my host machine (amd64
) and trying to install/configure libc-bin on a debian container, it gives me the following error:
[ cut for size, full log at https://pastebin.com/7ZtvqZsD ]
#6 18.65 Setting up libc-bin (2.31-13+deb11u3) ...
#6 18.92 qemu: uncaught target signal 11 (Segmentation fault) - core dumped
#6 19.03 Segmentation fault (core dumped)
#6 19.06 qemu: uncaught target signal 11 (Segmentation fault) - core dumped
#6 19.15 Segmentation fault (core dumped)
#6 19.15 dpkg: error processing package libc-bin (--configure):
#6 19.15 installed libc-bin package post-installation script subprocess returned error exit status 139
#6 19.20 Errors were encountered while processing:
#6 19.20 libc-bin
#6 19.31 E: Sub-process /usr/bin/dpkg returned an error code (1)
------
executor failed running [/bin/sh -c apt-get -y reinstall libc-bin]: exit code: 100
Minimal reproducible example
FROM arm64v8/debian
RUN apt-get -y update
RUN apt-get -y reinstall libc-bin
Versions
$ qemu-system-aarch64 --version # installed via pacman -S qemu-full
QEMU emulator version 7.0.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developer
$ qemu-system-arm --version # installed via pacman -S qemu-full
QEMU emulator version 7.0.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developer
$ docker --version
Docker version 20.10.17, build 100c70180f
## Binfmt extensions installed with
docker run --privileged --rm tonistiigi/binfmt --install all &
$ uname -a
Linux <hostname> 5.18.7-zen1-1-zen #1 ZEN SMP PREEMPT_DYNAMIC Sat, 25 Jun 2022 20:22:03 +0000 x86_64 GNU/Linux
## OS
Arch linux
Prior reading
(a.k.a. please don't mark my question as duplicates of these, it is distinct from them)
qemu: uncaught target signal 11 (Segmentation fault) - core dumped in docker containers
None of these answers work for me, I'm running the latest qemu in the arch linux repos, arm64v8/debian
is not a deprecated container image as far as I can tell, and I'm not using docker-for-mac. Plus, this question regards the opposite direction (amd64
containers on arm64
).
qemu: uncaught target signal 11 (Segmentation fault)
Issue doesn't stem from git, so this question's answer isn't helpful.
qemu-arm qemu: uncaught target signal 11 (Segmentation fault) - core dumped
Not helpful either, I've tried using qemu-user-static v7.0.0 (both compiled and -bin) which didn't fix my issue either. Not sure what the TCG interpreter is, so that could possibly be the issue, but I'm not familiar enough with qemu to know how to "disable the TCG interpreter".
qemu uncaught target signal 11 segmentation fault -- only on arm64 build
My kernel is 5.18.7-zen1-1-zen which is newer than the 5.10.0-8 that the answer suggests, and is the latest available on arch linux repos at time of writing.
qemu: uncaught target signal 11 (Segmentation fault) - core dumped, when trying to return a struct
Answers all related to C, which I'm not using.
Goal
My ultimate goal is to build a root filesystem using multistrap
to eventually be put on an arm64 device, but this issue is preventing me from doing pretty much anything, as running dpkg --configure -a
is one of the steps that has to be run from the very start.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在将我的头靠在这堵墙上数周之墙之后,我发现的解决方案是:
来自debian:11
而不是来自ARM64V8/debian:11
qemu-user static
在docker容器中apt install qemu-user static
qemu-aarch64 static
to rootfscp $(qemu-aarch64-static)/rootfs_location/usr/bin/bin/qemu-aarch64
(还请注意文件名更改)chroot/rootfs_location/
我不确定 为什么它可以工作,但这可能源于debian和qemu-user静态二进制文件之间的不兼容,这些二进制文件是为Arch Linux(或任何OS偶然使用的任何OS),但我不完全确定这一点。
After bashing my head against this wall for weeks, the solution I found was:
FROM debian:11
instead ofFROM arm64v8/debian:11
qemu-user-static
inside the docker containerapt install qemu-user-static
qemu-aarch64-static
to the rootfscp $(which qemu-aarch64-static) /rootfs_location/usr/bin/qemu-aarch64
(note the filename change as well)chroot /rootfs_location/
I'm not sure exactly why this works, but it likely stems from an incompatibility between debian and the qemu-user-static binaries that were compiled for arch linux (or whatever OSes happen to be used) but i'm not entirely sure of that.