Mysql: Docker container exits with code 139

Created on 12 Jun 2019  Â·  12Comments  Â·  Source: docker-library/mysql

Hello,
I am facing an issue when i want to run a mysql container: I tried with the example command i found on the Docker hub:

docker run --name some-mysql -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mysql:5.6.24

docker ps -a

Shows that the container exited with code 139
mysql:5.6.24 "/entrypoint.sh mysq…" 13 seconds ago Exited (139) 12 seconds ago some-mysql

And i can't have a single line of logs: the return of the docker logs command is empty...

question

Most helpful comment

I had the exact same behavior (error 139, no log output) for a mysql:5.5 image.
The only notable thing I did in between a working and a crashing container was to upgrade from Debian 9 to Debian 10. The mysql image was the only (so far) that stopped working.
rmiing the image, destroying the mysql container and then and pulling the image again solved my issue.

All 12 comments

What do the docker logs show for the container?

I'm not able to reproduce the issue

$ docker run --name some-mysql -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mysql:5.6.24
d671a4fce32d58e1f6e74ed96bf6ea46404c3822213820f26a3189174c95265b

$ docker ps
CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS               NAMES
d671a4fce32d        mysql:5.6.24        "/entrypoint.sh mysq…"   38 seconds ago      Up 33 seconds       3306/tcp            some-mysql

Maybe your local copy is corrupted, you could try docker image rm mysql:5.6.24 and re-pulling it

Hi,
That is the problem: docker logs shows absolutely nothing...

docker run --name some-mysql -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mysql:5.6.24
Unable to find image 'mysql:5.6.24' locally
5.6.24: Pulling from library/mysql
6e69f355f70e: Pull complete 
a3ed95caeb02: Pull complete 
2207cf04cde9: Pull complete 
0a2e8166cde7: Pull complete 
fce818e7de4b: Pull complete 
f4db7f77aeec: Pull complete 
bf8516093f28: Pull complete 
d34cadab8b95: Pull complete 
b7ed17133bd7: Pull complete 
Digest: sha256:6587cd1219e83d7f491be8be0e57201d3bfe864d525b31ecff53c338f690199f
Status: Downloaded newer image for mysql:5.6.24
2569c1a8cbd284557493e84ab5f5d19bace70a4094a72c87b63f56a68e82a0b9
docker ps -a
CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS                       PORTS               NAMES
2569c1a8cbd2        mysql:5.6.24        "/entrypoint.sh mysq…"   5 seconds ago       Exited (139) 4 seconds ago                       some-mysql
~ docker logs 2569c1a8cbd2 
~ 

Are you running on x86/amd64 architecture? That's the only one this image supports

I had the exact same behavior (error 139, no log output) for a mysql:5.5 image.
The only notable thing I did in between a working and a crashing container was to upgrade from Debian 9 to Debian 10. The mysql image was the only (so far) that stopped working.
rmiing the image, destroying the mysql container and then and pulling the image again solved my issue.

Hi,
Destroying and pulling the image did nothing for me... I'm still stuck with the issue

Are you using Docker for Windows/Mac or Linux Containers on Windows?

An Exited (139) is a segmentation fault so if it's not a corrupted download then there's some other environmental affect that's causing it, maybe even Apparmor or SELinux

I am currently using Docker for Debian

Yeah there isn't much more I can think of other than something odd in your environment affecting this.
And without a way to reproduce the issue I'd say you could try asking over at the Docker Community Forums, Docker Community Slack, or Stack Overflow

I also have this problem: exited with code 139 without any further logs. I try to upgrade to mysql 5.7.X, maybe this will resolve the error.

As mentioned above, this is likely environmental. One change between Debian 9 and 10 is the addition of AppArmor, so perhaps there's a new AppArmor policy causing trouble?

Closing since we cannot reproduce -- for further help/discussion, I'd suggest the Docker Community Forums, the Docker Community Slack, or Stack Overflow.

For me it was solved by updating the docker on my machine

It is very likely, that old glibc references are conflicting with new Debian 10 kernel, see workaround here:
https://github.com/docker/for-linux/issues/58#issuecomment-315150740

And kernel change is here:
https://anonscm.debian.org/cgit/kernel/linux.git/commit/?id=2aced7818ac46ca050ee68255ca20eeb14432a95

Was this page helpful?
0 / 5 - 0 ratings