[Mysql] mysql windows configuration file, mysql configuration file

Source: Internet
Author: User
Tags net command

[Mysql] mysql windows configuration file, mysql configuration file

The environment is win7 mysql5.6


Test whether the configuration file is available (no msyql configuration in windows has been used before)

Query the configuration before modification:
mysql> show variables like '%max_connections%';+-----------------+-------+| Variable_name   | Value |+-----------------+-------+| max_connections | 100   |+-----------------+-------+1 row in set

Modify the configuration file [mysqld] max_connections = 50
Restart mysql. If the net command can use net stop mysqlnet start mysql, and I cannot use it here, I will directly restart the service.
View after restart
mysql> show variables like '%max_connections%';+-----------------+-------+| Variable_name   | Value |+-----------------+-------+| max_connections | 100   |+-----------------+-------+1 row in set

It seems that the test was not successful. I still said that the test was not successful under c: \ WINDOWS on the Internet. Check the configuration on the official website. It is really not feasible for Baidu.
On Windows, MySQL Installer interacts with the user and creates a file named my. ini in the base installation directory as the default option file. if you install on Windows from a Zip archive, you can copy the my-default.ini template file in the base installation directory to my. ini and use the latter as the default option file.

From this section, we can see that it is placed in the installation directory .. Then I checked all the directories related to msyql and found a mysqldata directory with my. ini, I modified the connections value to 50, and the result takes effect.
It seems that it is still necessary to read the official documentation. Different installation methods may vary with versions, so you cannot copy other solutions.
'In summary, there are a total of these locations c: \ WINDOWS
Under the data directory under the installation directory
Data Directory Search Method
</pre><pre name="code" class="python">mysql> show variables like '%datadir%';+---------------+-----------------------------+| Variable_name | Value                       |+---------------+-----------------------------+| datadir       | D:\devsofts\mysqldata\data\ |+---------------+-----------------------------+1 row in set

This article from the "orangleliu notebook" blog, reprint please be sure to keep this source http://blog.csdn.net/orangleliu/article/details/41681927

Author orangleliu adopts signature-non-commercial use-share protocol in the same way


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.