报错版本:mysql-5.7.35
1、报错完整提示信息;
[root@localhost support-files]# ./mysql.server start
./mysql.server: line 239: my_print_defaults: command not found
./mysql.server: line 259: cd: /usr/local/mysql: No such file or directory
Starting MySQL ERROR! Couldn't find MySQL server (/usr/local/mysql/bin/mysqld_safe)
2、原因:
报错信息提示了,启动时没找见(/usr/local/mysql/bin/mysqld_safe)这个命令,我的安装路径不是默认的,是(/opt/software/mysql-5.7.35)
3、解决:
配置my.cnf文件的basedir为当前的安装路径在使用mysql.server启动就好了(mysql5.7某版本之后不提供my-default.cnf文件了,得自己去/etc下新创建文件然后打配置)
标签:mysql,server,报错,usr,MySQL,local From: https://www.cnblogs.com/liulangdian/p/16590078.html