我最近在计算机上安装了Manjaro,并且正在做一些测试。
我试图构建和启动一个可以在Windows,Mac OS,Ubuntu等上完美运行的Docker。
但是当我运行sudo docker-compose up
时出现错误。
除了最后,一切似乎都正常:
Successfully built d72aa4c69ad6
Successfully tagged code_interface:latest
WARNING: Image for service interface was built because it did not already exist. To rebuild this image you must use `docker-compose build` or `docker-compose up --build`.
Creating code_db_1 ... done
Creating code_web_1 ... done
Creating code_interface_1 ... done
Attaching to code_db_1, code_web_1, code_interface_1
code_db_1 exited with code 139
这是我的docker-compose.yml的样子:
db:
image: mongo:3.0.2
ports:
- "27017:27017"
web:
build: X
ports:
- "5000:5000"
links:
- db
interface:
build: Y
ports:
- "8080:8080"
links:
- web
知道为什么我会收到此错误或如何解决?
最佳答案
这可能与您计算机的内核版本有关,例如this issue中的报告:
This is probably related to the changes in vsyscall linking in the 4.11 kernel. Try booting the kernel with vsyscall=emulate and see if it helps. This does run ok under the linuxkit 4.11 kernel config without issues, so it is to do with the config.
尝试从this comment实现解决方案:
Hi, specifying this command in /etc/default/grub:
GRUB_CMDLINE_LINUX_DEFAULT="vsyscall=emulate"
让我们知道它是否可以为您解决问题。
关于docker - 如何在Manjaro上解决Docker错误代码139?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54517070/