MAC版本:10.15
MySQL版本:8.0.21
secure_file_priv的取值决定是否可以导出或导入文件
添加my.cnf
导入导出文件会出现无法导入导出,因为secure_file_priv
的值为NULL
mysql> show variables like "secure_file_priv";
因此需要在my.cnf文件中修改secure_file_priv
的值
secure_file_priv=""
但是mac的mysql版本中没有my.cnf文件,需要自己写:
- 打开文件命令:
sudo vi /usr/local/