简体   繁体   English

docker 在运行时立即退出,错误代码为 139

[英]docker is exited immediately when runs with error code 139

I have a web api project with running fine when i ran through visual studio, able to build the image also.我有一个 web api 项目,当我通过 Visual Studio 运行时运行良好,也能够构建图像。 but when i run using the command但是当我使用命令运行时

docker run -d -t -p 8000:83 8fbf296e2173

shows no error and the container will be listed in docker ps -a with the status显示没有错误,容器将在docker ps -a列出,并带有状态

Exited (139) 1 second ago

Please help to solve this请帮忙解决这个问题

It's impossible to say what the root cause is without knowing more about the image that is running.如果不了解正在运行的映像的更多信息,就不可能说出根本原因是什么。 But, the Exited (139) basically means the PID 1 of the container was sent SIGKILL .但是, Exited (139)基本上意味着容器的 PID 1 已发送SIGKILL It could be anything, segfault, out of memory, stack overflow, etc.它可以是任何东西,段错误,内存不足,堆栈溢出等。

Started using WSL 2 and encountered the same issue.开始使用 WSL 2 并遇到相同的问题。 The workaround posted here has resolved things for me: https://github.com/microsoft/WSL/issues/4694#issuecomment-556095344此处发布的解决方法为我解决了问题: https : //github.com/microsoft/WSL/issues/4694#issuecomment-556095344

I faced the same issue while trying to connect to port 1433 from my host to docker (error code 139).我在尝试从主机连接到端口 1433 到 docker 时遇到了同样的问题(错误代码 139)。 I was able to resolve it by using Administrator: Windows Powershell .我能够使用Administrator: Windows Powershell解决它。

For anyone's future reference;供任何人日后参考; Docker exit code 139 ( 128 + 11 ) means that a container received a SIGSEGV . Docker 退出代码139 ( 128 + 11 ) 表示容器收到了SIGSEGV This may be a result of invalid memory reference.这可能是无效内存引用的结果。

Ref: https://stackoverflow.com/a/35410993/7160815参考: https : //stackoverflow.com/a/35410993/7160815

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

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