

This is the lowest level, where data is in the read-only, immutable image itself. Please run mysql_upgrade to create it.ġ70328 16:03:13 InnoDB: Database was not shut down normally!ġ70328 16:03:13 InnoDB: Starting an apply batch of log records to the database. usr/sbin/mysqld: Table 'ugin' doesn't existġ70328 16:03:13 Can't open the ugin table. Then I have these errors in /var/log/mysql/error.log. Some were re-created with the owner staff instead of mysql. everything is broken! All the files in the /var/lib/mysql directory were removed.

I " bind" a local folder to the named volume with Kitematic (see below), the container automatically restarts and. However, let's say I want to retrieve the data on my host machine (Windows 10, I installed Docker via the Docker Toolbox). So far, everything works as expected, including the database. ĭocker run -dt -v database_volume:/var/lib/mysql mysql-persist-test:0.1 I build and run the image this way: docker build -t mysql-persist-test:0.1.
#Kitematic automatically add local folder for volumes install
RUN apt-get update -y & apt-get install -y apt-utils & \Įcho "mysql-server mysql-server/root_password password $MYSQL_ROOT_PASSWORD" | debconf-set-selections & \Įcho "mysql-server mysql-server/root_password_again password $MYSQL_ROOT_PASSWORD" | debconf-set-selections & \Īpt-get install -y mysql-server mysql-client & service mysql start yes, you guessed it: I'd like to persist the data. I've built a custom image using a Dockerfile. However, it seems a lot of beginners struggle to persist their data when using Docker. I'm new to the Docker world and I'm trying to achieve something one could think is trivial.
