mysql --help|grep 'my.cnf' 查看mysql启动时读取配置文件的默认目录 命令 mysql --help|grep 'my.cnf' 输出 order of preference, my.cnf, $MYSQL_TCP_PORT, /etc/my.cnf /etc/mysql/my.cnf /usr/local/etc/my.cnf ~/.my.cnf /etc/my.cnf, /etc/mysql/my.cnf, /usr/local/etc/my.cnf, ~/.my…