상세 컨텐츠

본문 제목

Docker Fatal Error On Start Issue 2571 Docker/for-mac Github

카테고리 없음

by cialetenmi1984 2020. 2. 9. 01:26

본문

Feb 6, 2018 - Expected behavior Docker start normally Actual behavior Docker hangs/crash on startup Information Docker diagnostic ID:. For the Docker environment the start still fails [ERROR] Fatal error: Can't open and lock privilege tables: Table storage engine for 'user' doesn't have this option. Running the script. Sh mysqltest.sh root. Github.com - docker/for-linux - Issues - MySQL does not start with overlay2 and overlay but starts with aufs. Expected behavior Running my containers works as it did in the previous version. Actual behavior After update to beta18, I re-launched my containers from a script and got this error: + docker run -d --restart=alway.

I created a test project for the issue.

Docker Fatal Error On Start Issue 2571 Docker/for-mac Github

This error message shows up when I use ubuntu 16.04 and the latest mysql 5.7.19-0ubuntu0.16.04.1 in a Docker image. What could be done to fix this?

Docker Fatal Error On Start Issue 2571 Docker/for-mac Github Desktop

To reproduce the error. Get the Dockerfile: FROM ubuntu:16.04 RUN apt update RUN DEBIANFRONTEND=noninteractive apt install -y mysql-server (also available ). Build and run: docker build -t mysqlfail. Docker run -it mysqlfail tail -1 /var/log/mysql/error.log would have been shown the following error log: 2017-08-26T11:45Z 1 Warning root@localhost is created with an empty password! Please consider switching off the -initialize-insecure option. Which was exactly what we wanted: a mysql with no root password set yet. In the past (ubuntu 14.04 / mysql 5.5) a service mysql start was possible.

Now if you try this it fails docker run -it mysqlfail service mysql start. Starting MySQL database server mysqld No directory, logging in with HOME=/ fail and /var/log/mysql/error.log contains a line: 2017-08-26T11:18Z 0 ERROR Fatal error: Can't open and lock privilege tables: Table storage engine for 'user' doesn't have this option build log (for the complete ) Sending build context to Docker daemon 2.56kB Step 1/4: FROM ubuntu:16.04 - ebcd9d4fca80. Step 4/4: RUN service mysql start - Running in 5b899739d90d. Starting MySQL database server mysqld.fail! The command '/bin/sh -c service mysql start' returned a non-zero code: 1 weird continuation After experiments as outlined in, I created a shell script that does a select count(.) query on each table in the mysql space three times in a row (because experiments show that on some tables the query will fail exactly twice:-( ). Then a mysqlupgrade and the service mysql restart is tried. In the Dockerfile the script is made available via COPY mysqltest.sh.

Docker Fatal Error On Start Issue 2571 Docker/for-mac Github

Docker Fatal Error On Start Issue 2571 Docker/for-mac Github Ultratype

The trials with this script give weird/crazy results. This might not quite be the solution yet.

Anyways it might point others to a 'proper' answer The docker bash session log below shows a sequence of steps that lead to strange errors and finaly being able to start the mysql daemon properly in the docker environment. Trying to start the daemon in this session fails twice - once due to the mysql.user table and once due to the mysql.db table. Running the mysql daemon with -skip-grant-tables works but there is also problems with simple select.

from commands on these tables. Strangely doing two simple queries: select host,user from mysql.user; select user from mysql.db and then killing the daemon to start it properly with service mysql start seems to work. I'll now try to automate this as a workaround.

I am still seeking for a 'proper' solution to the problem and some clue what the reason for this strange behavior is. Dockerfile #. # # Dockerfile for # #. # Ubuntu image FROM ubuntu:16.04 # # Maintained by Wolfgang Fahl / BITPlan GmbH # MAINTAINER Wolfgang Fahl info@bitplan.com RUN export DEBIANFRONTEND=noninteractive;apt-get update -y && apt-get install -y vim mysql-server RUN mkdir /var/run/mysqld;chown mysql /var/run/mysqld WORKDIR /var/log/mysql build log docker build.