故障1:如果运行docker-compose up 报"Cannot create redo log files because data files are corrupt or the database was not shut down cleanly after creating the data files"是没有安装下面的依赖包,记得安装依赖包,如下图所示
故障2:如果运行docker-compose up 报"--initialize specified but the data directory has files in it. Aborting."是挂载的目录下面还存在文件或者权限不够,记得删除整个文件夹再添加,存在界面看不出有文件,但是命令行ll可以查看到文件
bash复制代码
[root@apple mysql]# cd data
[root@apple data]# ll
总用量 4
-rwxrwxrwx 1 systemd-coredump input 13 1月 2 09:18 OFF.~rec~
[root@apple data]#