Skip to content

Latest commit

 

History

History
12 lines (8 loc) · 496 Bytes

File metadata and controls

12 lines (8 loc) · 496 Bytes

注意事项

mysql.sock不要放在tmp目录下面

执行命令,更改mariadb.sock文件位置,防止/tmp目录下文件被删除导致挂掉

sed -i "s/\/tmp\/mariadb.sock/\/data\/mariadb\/mariadb.sock/g" /etc/my.cnf.d/client.cnf 
sed -i "s/\/tmp\/mariadb.sock/\/data\/mariadb\/mariadb.sock/g" /etc/my.cnf

修改完确认上面命令中的两个文件是不是都成功修改了mariadb.sock的目录,为/data/mariadb/mariadb.sock,如果没有手动修改。