ubuntu 下Mysql导入导出文件报错:ERROR 1290 (HY000): --secure-file-priv
2016-12-09 19:46
951 查看
1.报错原因:
secure_file_priv设置了指定目录,需要在指定的目录下进行数据导出
通过命令:mysql> show variables like '%secure%'; 查看变量的值
所以在导入导出的时候,文件应该在此目录下。
2.secure_file_priv参数说明
这个参数用来限制数据导入和导出操作的效果,例如执行LOAD DATA、SELECT ... INTO OUTFILE语句和LOAD_FILE()函数。这些操作需要用户具有FILE权限。
如果这个参数为空,这个变量没有效果;
如果这个参数设为一个目录名,MySQL服务只允许在这个目录中执行文件的导入和导出操作。这个目录必须存在,MySQL服务不会创建它;
如果这个参数为NULL,MySQL服务会禁止导入和导出操作。这个参数在MySQL 5.7.6版本引入。
secure_file_priv设置了指定目录,需要在指定的目录下进行数据导出
通过命令:mysql> show variables like '%secure%'; 查看变量的值
所以在导入导出的时候,文件应该在此目录下。
2.secure_file_priv参数说明
这个参数用来限制数据导入和导出操作的效果,例如执行LOAD DATA、SELECT ... INTO OUTFILE语句和LOAD_FILE()函数。这些操作需要用户具有FILE权限。
如果这个参数为空,这个变量没有效果;
如果这个参数设为一个目录名,MySQL服务只允许在这个目录中执行文件的导入和导出操作。这个目录必须存在,MySQL服务不会创建它;
如果这个参数为NULL,MySQL服务会禁止导入和导出操作。这个参数在MySQL 5.7.6版本引入。
相关文章推荐
- mysql 导出数据到文件 ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so
- Windows下MySQL导入csv文件ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv opti
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it ...statemet
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- mysql导出表到CSV文件方法及提示错误[Err] 1290 - The MySQL server is running with the --secure-file-priv option解决办法
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot execute this statement
- MySQL 报错 ERROR 1290 (HY000): running with the --secure-file-priv
- MySQL导入及导出文件出错ERROR 1290 (HY000)解决方法
- ERROR 1290 (HY000): The MySQL server is running with the --secure-file-priv option so it cannot exec
- Linux下MySQL导入文件出错ERROR 1290 (HY000)
- Linux下MySQL导入文件出错ERROR 1290 (HY000)
- csv导入mysql提示错误[Error Code] 1290 - The MySQL server is running with the --secure-file-priv option 解决方
- mysql导出数据时提示错误1290(secure_file_priv)的解决办法
- Mac上csv导入mysql提示错误[Error Code] 1290 - The MySQL server is running with the --secure-file-priv option
- Windows10 MySQL5.7.21.0 ERROR 1290 (HY000): The MySQL server is running with the --secure-file-p解决办法
- Ubuntu Server 14.04 --secure-file-priv error in MySql 解决方案