The MySQL server is running with the –secure-file-priv option so it cannot execute this statement.

在我们安装完 MySQL 之后,会自动生成一个名为my.ini的配置文件,该文件记录了 MySQL 的所有默认配置,如端口号、默认字符集、默认存储引擎等等。而这个配置文件,则位于隐藏文件夹ProgramData中

我们也可以通过命令查看secure-file-priv的当前值:

show variables like '%secure%';

查询显示:

ecure-file-priv="C:/ProgramData/MySQL/MySQL Server 5.7/Uploads"

我们可以通过打开my.ini配置文件进行查看及修改:

image.png

如上图所示,我注释了 MySQL 的默认值,并修改成自己指定的路径。在我修改此配置文件的内容之后,例如修改了secure-file-priv的默认值,要想使其生效,必须关闭 MySQL 然后重新启动。需要我们注意的是:关闭 MySQL 并不是指简单的用exit命令退出 MySQL 或者关闭 MySQL 窗口,而是关闭 MySQL 服务,然后重新启动服务。

mysql safe file priv_mysql --secure-file-priv问题解决方案相关推荐

  1. mysql 启动错误-server PID file could not be found

    2019独角兽企业重金招聘Python工程师标准>>> [root@centos var]# service mysqld stop MySQL manager or server ...

  2. MySQL is running but PID file is not found

    今 天vps访问速度很慢,我用/root/lnmp restart 命令给lnmp重启了一下,重启之后发觉mysql链接不上了. ssh里面运行 service mysql restrat 出现 My ...

  3. SSH Secure File Transfer上传文件错误:encountered 1 errors during the transfer解决办法

    在使用SSH 工具向Linux服务器上传文件时,弹出 encountered 1 errors during the transfer 错误. 解决方案: 1.准备上传的那个文件所在目录路径存在(), ...

  4. MySQL is running but PID file could not be found(在macOS系统下解决方法)

    首次安装mysql后 修改好环境变量,测试mysql是否安装成功时 sudo mysql.server status 提示:MySQL is running but PID file could no ...

  5. SSH Secure File Transfer 传输错误解决方法

    使用SSH Secure File Transfer 往服务器上传文件时,系统报错:encountered 1 errors during the transfer 解决方法,将要往服务器上传文件的路 ...

  6. 重启服务器后mysql表损坏 Incorrect key file for table ‘.\axxxx.MYI‘; try to repair it“,“tourl“:““,.....

    重启系统后mysql表损坏 Incorrect key file for table '.\axxxx.MYI'; try to repair it","tourl":& ...

  7. [error] [mysql]:1034 Incorrect key file for table 'table_name'; try to repair it

    [error] [mysql]:"1034 Incorrect key file for table 'table_name'; try to repair it" 现象描述: m ...

  8. File.separator或File.pathSeparator

    本文翻译自:File.separator or File.pathSeparator In the File class there are two strings, separator and pa ...

  9. mysql safe无法启动_(转)mysqld_safe无法启动的解决办法

    启动mysql时报错: Starting mysqld daemon with databases from /var/lib/mysql STOPPING server from pid file ...

  10. error while loading shared libraries: libaio.so.1: cannot open shared object file: No such file

    原文地址:mysql安装报错error while loading shared libraries: libaio.so.1: cannot open shared object file: No ...

最新文章

  1. 为什么做java的web开发我们会使用struts2,springMVC和spring这样的框架?
  2. Linux系统中的函数
  3. Aix下如何运行Java程序
  4. Python 那些永远用不到的对象,我们称之为「垃圾」
  5. 皇牌空战无限服务器,《皇牌空战:无限》正式停服 一个搏击长空的时代终结[多图]...
  6. mac 显示隐藏文件的命令行和快捷键
  7. [No000014]听说不背单词,考英语会是这种下场-我们为什么必须背单词?
  8. 元宵诗词各一【明书】
  9. 2.用户画像:方法论与工程化解决方案 --- 数据指标体系
  10. 光环大数据python爬虫
  11. Docker 学习笔记(四)-- Docker 可视化界面
  12. 流体力学及其工程应用
  13. Spring连环CVE-2015-5211和CVE-2020-5421漏洞升级教程!
  14. 12岁的B站,放慢脚步做社区
  15. 英谷Oracle答案,火焰纹章风花雪月各角色能学什么魔法 各角色可习得魔法与熟练度要求一览...
  16. 设备零线地线短路维修
  17. MySQL--数据库基础知识点(一)
  18. 如何查看服务器系统时间,服务器时间相关(硬件时间,系统时间,时区时间)...
  19. Vue与Node.js实现手机短信验证登录
  20. WebRTC基础实践 - 5.通过RTCPeerConnection传输流媒体视频

热门文章

  1. 一篇文章学习完RabbitMQ
  2. 工商银行转账出现java_工行企业网银转账提示信息代码4506是什么意思?
  3. S7-200SMART 模拟量间接寻址 批量处理
  4. mars2d解决底图上下拖动超出边界出现灰色底
  5. [codechef] TOURISTS
  6. wamp5 开启 ssl
  7. 计算机卷死,一位计算机教师死了,警方在床底发现一张纸,上面写着一些特殊的符号,这... #119615-推理漫画-侦探推理-33IQ...
  8. 计算机无法识别 此硬盘,如果计算机无法识别硬盘驱动器,该怎么办?
  9. 繁簡替互換(SQL)
  10. python基础--del操作