Can't connect to MariaDB 10 from PC after cumulative update for Windows 10 version 1903

vuille-jp's profile image vuille-jp posted 5 years ago in Creating a connection Permalink

Can't connect to MariaDB 10 from PC after cumulative update for Windows 10 version 1903. Same behaviour on 3 different PCs on same network, whereas connecting with phpMyAdmin works fine on all PCs. Error message is "Can't connect to MySQL server on 'localhost' (10061)". I have strictly the same host name, user name and password on HeidiSQL and phpMyAdmin. On the other side, connecting to MariaDB5 works fine. Has anyone experienced the same?

ansgar's profile image ansgar posted 5 years ago Permalink

Yes, I had the same issue here. I had two mysql services running on different ports, and the one I was mostly using was somehow using the my.ini file from the other service, so it could not start up. Turned out to be a environment path problem. I fixed that path so the service was starting again. Also I had to recreate a Windows firewall rule for mysqld.exe .

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

Thank you Ansgar. Can you please elaborate? Are you talking services and paths on Windows or on Linux? I have no mysql service listed in services.msc on my PC. I have putty to view files on Linux, but I am not so familiar with it. Your help will be appreciated.

ansgar's profile image ansgar posted 5 years ago Permalink

I meant services on my local Windows 10 machine. Every configured remote session kept working like before. It was just a local problem. I was assuming you were doing the same, as you mentioned the error message "can't connect to mysql server on localhost".

Which network type is it in heidisql? (first drop-down on the session manager)

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

I have MariaDB 5 and MariaDB 10 both installed on a Synology NAS. On the same LAN, I have 3 PCs all running HeidiSQL v10.2 under Windows 10 v1903. My web browser is Firefox. Network type in HeidiSQL is "MariaDB or MySQL (TCP/IP)". I have several users, either ...@localhost or ...@%. All access MariaDB 5 from any PC, but none can access MariaDB 10 since last Windows 10 cumulative update (KB4512508, 2019-8).

ansgar's profile image ansgar posted 5 years ago Permalink

Maybe you need to open the second port in your (Windows) firewall ?

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

My firewall is by Avast. Windows firewall is not active. I have turned off all Avast protections for 10 min and tried to start HeidiSQL on port 3307. Unfortunately, it fails also. Can you please elaborate on what you told me earlier, concerning running services and my.ini file. Where are they located (paths)? I have no mysql service running on services.msc.

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

In addition, phpMyAdmin connects OK from all PCs, which means port 3307 is allowed through firewall

ansgar's profile image ansgar posted 5 years ago Permalink

Ok then please post the hostname (as your error was saying "localhost"). And please also post the exact error message you get on all pcs.

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

Host name is snarcor.ch. IP address on internet is 85.0.155.159. Local IP address on LAN is 192.168.1.2. Error message is "Can't connect to MySQL server on 127.0.0.1 (1061)" or "Can't connect to MySQL server on 'snarcor.ch' (1061)" depending on which host name I specify in session manager.

vuille-jp's profile image vuille-jp posted 5 years ago Permalink

The problem is solved ! I read in different forums that in '@my.cnf' bind-address must be either commented out or set at 0.0.0.0. Si I did, then I stopped and restarted both MariaDB servers (MariaDB 5 and 10). Now I can successfully access both MariaDB 5 and MariaDB 10. Part of the difficulty was that the path to '@my.cnf' is not the same for both:

  • for MariaDB 5: /etc/mysql/
  • for MariaDB10: /usr/local/mariadb10/etc/mysql

Thank you for again for you kind attention into my problem.

Please login to leave a reply, or register at first.