Use docker to create a container based on the official image ubuntu 16.04.3, which cannot be started normally after installing mysql server

after initialization of the container, there is no problem with installing mysql-server and starting it for the first time, but when I exit the container and enter again, I will not be able to start mysql-server normally

the following error was returned when executing service mysql start:

/ usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied

  • Starting MySQL database server mysqld / usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied

No directory, logging in with HOME=/
/ usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied
/ usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied
/ usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied
/ usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot stat shared object: Permission denied

< hr >

the following is my software version
docker Client and Server Version: 18.02.0-ce
ubuntu version: 16.04.3 LTS
mysql Ver 14.14 Distrib 5.7.21, for Linux (x86 million 64) using EditLine wrapper

Mar.03,2021

what user are you using to operate, indicating that you do not have access rights.
try sudo service mysql start
whether you quit the container and shut down the terminal or exit


brother did not solve, I also encountered the same problem.


this is due to the fact that ubuntu 14.04 is on the outside and the docker inside is 16.04.
if you do not upgrade the latest docker 18.03
, you can return to docker 17.03.1 to return to normal. If 18.03 is installed, it cannot be returned. You can only upgrade external hosts to 16.04.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b367f4-2c015.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b367f4-2c015.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?