查看mysql版本

lihudeMacBook-Pro:~ SunAndLi$ mysql --version

 错误:

-bash: mysql: command not found

lihudeMacBook-Pro:bin SunAndLi$ sudo ln -fs /usr/local/mysql/bin/mysql mysql

 进入mysql

lihudeMacBook-Pro:bin SunAndLi$ mysql -u root -p

 开启log

mysql> set global general_log=on;  

 查询log的位置

mysql> show variables like 'general_log_file';

重启mysql

lihudeMacBook-Pro:StartupItems SunAndLi$ sudo /usr/local/mysql/support-files/mysql.server restart

 

相关文章:

  • 2022-02-08
  • 2021-09-29
  • 2022-01-19
  • 2021-12-01
猜你喜欢
  • 2021-12-18
  • 2021-07-06
  • 2021-11-26
  • 2021-09-18
  • 2021-12-18
  • 2021-11-13
  • 2022-12-23
相关资源
相似解决方案