mysql import error
mysql导入文件一直出错,显示ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot execute this statement。
查看了mysql版本临时目录相关变更,在MySQL 5.7.6版本之后,导入文件只能在secure_file_priv指定的文件夹下
用show variables like '%secure%';命令显示文件目录
+--------------------------+-----------------------+
| Variable_name | Value |
+--------------------------+-----------------------+
| require_secure_transport | OFF |
| secure_auth | ON |
| secure_file_priv | /var/lib/mysql-files/|
+--------------------------+-----------------------+
3 rows in set (0.00 sec)
OK,临时路径改成这个即可。