I'm using MySQL for Windows (installed through Oracle's official setup utility), and I don't want MySQL to accept connections that are NOT coming from a specific host (in this case it's a certain domain). Been using Linux before and thus I know that there was something about my.cnf
where I simply had to change the bind-address
value. However, I cannot find this file using Windows. Any tips for me?
Asked
Active
Viewed 1.9k times
2

Jan
- 23
- 1
- 1
- 3
-
There are docs for Windows too. Have you considered reading them? – Mad Physicist Mar 11 '16 at 14:42
-
1Possible duplicate of [I can not find my.cnf on my windows computer](https://stackoverflow.com/questions/1712646/i-can-not-find-my-cnf-on-my-windows-computer) – Lech Migdal Dec 31 '18 at 20:44
2 Answers
2
with mysql 8 on windows 10, you can edit with admin privileges the file: my.ini in the directory: C:\ProgramData\MySQL\MySQL Server 8.0
remark: you can find this path via properties of service, as it is referenced in commandline:
in section: [mysqld] set (it might not exist so add the line): bind_address=127.0.0.1
Restart windows service:
sc query MySQL80
sc stop MySQL80
sc start MySQL80
then check via netstat that binding adress
netstat -abn
TCP 127.0.0.1:3306 0.0.0.0:0 LISTENING
[mysqld.exe]

Thierry Brémard
- 625
- 1
- 5
- 14
-3
Have a look here:
http://dev.mysql.com/doc/refman/5.6/en/option-files.html
It gives you all the positions and reading sequence of MySql configuration files in Windows.

White Feather
- 2,733
- 1
- 15
- 21