Fixed: "MySQL server is running with the –secure-file-priv” Error
The variablesecure_file_priv is used to limit the effect of data import and export operations.
Example of the affected operations is those performed by the LOAD DATA andSELECT ... INTO OUTFILE statements and the functionLOAD_FILE(). These operations are permitted only to users who have the FILE privilege.
mysql> SHOW VARIABLES LIKE "secure_file_priv";Changing secure-file-priv variable directory
+------------------+-----------------------+
| Variable_name | Value |
+------------------+-----------------------+
| secure_file_priv | /var/lib/mysql-files/ |
+------------------+-----------------------+
[mysqld]sudo systemctl restart mysqldDiable secure-file-priv variable To disable it, set the variable to an Empty value.
secure-file-priv=/new-location
[mysqld]sudo systemctl restart mysqld
secure-file-priv = ""
Comments
Post a Comment