Home  >  Q&A  >  body text

Docker镜像在本地构建成功,但是运行起来的时候,镜像内部的Mysql启动出错

docker version
Client version: 0.9.1
Go version (client): go1.2.1
Git commit (client): 3600720
Server version: 0.9.1
Git commit (server): 3600720
Go version (server): go1.2.1
git clone https://github.com/sameersbn/docker-redmine.git
cd docker-redmine
docker build -t xx/redmine .
docker logs -f $(docker run -d xx/redmine)
User: root Password: eiThoo9iecoa
sshd: started
mysqld: ERROR (abnormal termination)

看到吧。是mysqld启动问题。

怪我咯怪我咯2761 days ago785

reply all(2)I'll reply

  • ringa_lee

    ringa_lee2017-04-21 10:58:46

    I am maintaining a mysql image, which contains volume processing code. You can run it to see if the image can run normally.
    https://github.com/tutumcloud/tutum-docker-mysql

    In addition, another blog I wrote has an introduction to mysql volume. You can refer to it: http://blog.tutum.co/2014/05/27/containerize-your-database-volume-with-tutum-mysql -images/

    reply
    0
  • PHP中文网

    PHP中文网2017-04-21 10:58:46

    I also encountered this problem. I could start it normally without adding the -v /host/data:/var/lib/mysql parameter
    After adding it, the owner of /var/lib/mysql of the container is not mysql. This is a permission problem, and then I can’t get up
    It seems like this

    reply
    0
  • Cancelreply