MySQL my.ini location

前端 未结 14 2237
梦如初夏
梦如初夏 2020-11-27 12:17

I have already seen http://dev.mysql.com/doc/refman/4.1/en/mysql-config-wizard-file-location.html

how to know mysql my.cnf location

and

http://dev.

相关标签:
14条回答
  • 2020-11-27 12:53

    programData is hidden folder so you have to change the option from setting to show hidden folder and then make the change in my.ini file present in that.

    Be sure to update the correct my.ini file because it can waste a lot of your time if you keep updating wrong file.

    You can look into service to see which my.ini is configured in this service.

    0 讨论(0)
  • 2020-11-27 12:54

    it is there at C:\Program Files\MySQL\MySQL Server 5.5 there are various .ini files with small, medium & large names. generally medium is used or it depends on your requirement.

    0 讨论(0)
  • 2020-11-27 12:56

    Answered for only MySQL Workbench users,

    0 讨论(0)
  • 2020-11-27 12:57

    In my case, the folder ProgramData was hidden by default on windows 7, so I was unable to find my.ini file.

    After selecting show hidden files and folders option, I was able to find the my.ini file at the location: C:\ProgramData\MySQL\MySQL Server 5.6.

    Display hidden files and folders on windows 7:

    1. Right-click the Windows Logo button and choose Open Windows Explorer.

    2. Click Organize and choose Folder and Search Options.

    3. Click the View tab, select Show hidden files and folders and then clear the checkbox for Hide protected system operating files.

    4. Click Yes on the warning and then click OK.

    0 讨论(0)
  • 2020-11-27 12:59

    my.ini LOCATION ON WINDOWS MYSQL 5.6 MSI (USING THE INSTALL WIZARD)

    Open a Windows command shell and type: echo %PROGRAMDATA%. On Windows Vista this results in: C:\ProgramData.

    According to http://dev.mysql.com/doc/refman/5.6/en/option-files.html, the first location MySQL will look under is in %PROGRAMDATA%\MySQL\MySQL Server 5.6\my.ini. In your Windows shell if you do ls "%PROGRAMDATA%\MySQL\MySQL Server 5.6\my.ini", you will see that the file is there.

    Unlike most suggestions you will find in Stackoverflow and around the web, putting the file in C:\Program Files\MySQL\MySQL Server 5.6\my.ini WILL NOT WORK. Neither will C:\Program Files (x86)\MySQL\MySQL Server 5.1. The reason being quoted on the MySQL link posted above:

    On Windows, MySQL programs read startup options from the following files, in the specified order (top items are used first).

    The 5.6 MSI installer does create a my.ini in the highest priority location, meaning no other file will ever be found/used, except for the one created by the installer.

    The solution accepted above will not work for 5.6 MSI-based installs.

    0 讨论(0)
  • 2020-11-27 13:00

    You have to look I the folder C:\Program Files\MySQL\MySQL Server 5.5 but there is a problem. When you perform an MSI install of MySQL, my.ini is not created. There will be sample .ini files in that folder. In order to use one of them, say my-medium.ini, you need to do the following before a MySQL restart:

    cd C:\Program Files\MySQL\MySQL Server 5.5
    copy my-medium.ini my.ini
    net stop mysql
    net start mysql
    

    Once, you do this, my.ini can be read by C:\Program Files\MySQL\MySQL Server 5.5\bin\mysql.exe.

    0 讨论(0)
提交回复
热议问题