debootstrap 不会提取 libc6,不会创建 /sbin/ldconfig

debootstrap 不会提取 libc6,不会创建 /sbin/ldconfig

我正在使用 dbootstrap 创建 chroot 根文件系统 (Ubuntu 14.04),以便稍后使用它来映像另一台机器。我指定了所有必要的软件包,debootstrap 似乎检索、验证并开始提取所有软件包(包括 lib6c,它应该包含 /sbin/ldcofig),但我收到以下错误:

user@computer:~$ debootstrap --arch=amd64 --include=....,libc6,.... /rootfs
...
...
I: Extracting libc6...
....
I: Extracting util-linux...
I: Extracting xz-utils...
I: Extracting zlib1g...
W: Failure trying to run: chroot /home/../rootfs /sbin/ldconfig

我认为在提取 libc6 时应该创建 /sbin/ldconfig(进入“rootfs”),但它没有创建该文件。这意味着 debootstrap 无法 chroot 该文件,从而导致上述错误消息。

为什么提取 libc6 不会导致创建 /sbin/ldconfig?debootstrap 这里还需要什么?

编辑:我注意到 /bin/sh(也是运行上述失败命令所必需的)也丢失了,因此没有提取。知道为什么丢失了吗?

答案1

解决了。
​​我没有指定完整的软件包列表(libc-bin并且dash缺少许多其他软件包),这阻止了 debootstrap 完成其工作。我最终使用了更新的软件包列表,这解决了我的问题。

相关内容