Mac configuration MySQL encountered--secure-file-priv problem

Source: Internet
Author: User

1. Install MySQL

Installation on the official website, step-by-step barrier-free installation (but based on the experience of importing/exporting files in the future, it would be preferable to set Secure-file-priv to empty,5.7.6 after Setup before installing it, which would appear to be null by default and secure-file-prive null. File import/exit is not supported)

2. Install Navicat Premimum

Find a cracked version on the Internet, follow the steps to install the hack, very useful

3. Problem encountered: When exporting selected records to a. csv file, a prompt appears "the MySQL server is running with the--SECURE-FILE-PRIV option so it cannot execute this St Atement ".

Steps to resolve:

(1) query variable: mysql---show variables like '%secure% ', found that my secure-file-priv value is null. If it is a file path, the import/export of the file path is placed under this path, but if it is null, the SECURE-FILE-PRIV should be set.

(2) My system is OS Sierra 10.11.6, the My.ini file cannot be found under the MySQL folder (Windows system should have this), only in/usr/local/mysql-5.7.16-osx10.11-x86_64/ Support-files found a my-default.cnf configuration file, copy it, and open the file, add the statement as shown, save it as "my.cnf" file. But this file doesn't work in this folder, so I'll just copy it into the/private/etc. Attention?? The configuration file is ready to restart the MySQL server before it is valid.

Mac configuration MySQL encountered--secure-file-priv problem

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.