简体   繁体   English

未知主机 QEMU_IFLA 类型:50 intalling python on docker

[英]Unknown host QEMU_IFLA type: 50 intalling python on docker

I'm trying to create a docker image to compile python libraries for arm on a x86 instance.我正在尝试创建一个 docker 图像来编译 python 库 arm 在 Z8A9DA7865483C5ACED359F3 实例上。

This is the process I'm following:这是我正在遵循的过程:

1) Install quemu: 1)安装quemu:

sudo apt-get install qemu qemu-user-static qemu-user binfmt-support

2) Get a docker image for raspberry pi: 2) 获取树莓派的 docker 图像:

  sudo  docker pull balenalib/raspberrypi3

3) Run the image in interactive mode: 3)以交互模式运行图像:

 sudo docker run -it resin/raspberrypi3-debian /bin/bash

Now the error is occurring on the container at this line:现在错误发生在这一行的容器上:

sudo apt-get install python3-dev libffi-dev libssl-dev -y

The complete error is:完整的错误是:

root@255c2b870446:/# sudo apt-get install python3-dev libffi-dev libssl-dev -y
Unknown host QEMU_IFLA type: 50
Unknown host QEMU_IFLA type: 51
Unknown host QEMU_IFLA type: 50
Unknown host QEMU_IFLA type: 51
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package python3-dev
E: Unable to locate package libffi-dev
E: Unable to locate package libssl-dev

I know is installing the libraries over the running container is not the right approach, I'm doing it this way to test them one by one an get a sense on how this will work and the common issues.我知道在正在运行的容器上安装库不是正确的方法,我这样做是为了一一测试它们,以了解这将如何工作以及常见问题。

this will work:这将起作用:

apt-get update && apt-get install python3-dev libffi-dev libssl-dev -y

you need to make that as a routine to run update before installing new packages on Docker Containers and you do not need also to run it with sudo since you are already the root in this container在 Docker 容器上安装新软件包之前,您需要将其作为例行程序运行update ,并且您也不需要使用 sudo 运行它,因为您已经是此容器中的根

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM