I am trying to connect HeidiSql from the host to my WSL Mysql but I could not get it to connect it
Error "can't connect to Mysql server on '127.0.0.1'"
Tried SSH too but could not connect to the server
Go to Settings -> Network and Internet -> Status -> View Hardware and connection properties. Look for the name vEthernet (WSL). It will usually be on the bottom.
You can list your installed Linux distributions and check the version of WSL each is set to by entering the command: wsl -l -v in PowerShell or Windows Command Prompt.
I'm also hosting mysql-server on WSL and running MySQL workbench on Windows.
I had to get the IP inside of WSL
And use this IP in MySQL Workbench
As for me who's also using WSL for making web based application
first make sure mysql is running on WSL like sudo service mysql start
then once started, open HeidiSql and simply connect to it, here the example on my part
make sure the IP address is 127.0.0.1 not any IP, not your IP used to connect on the internet
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With