Current location - Quotes Website - Collection of slogans - How to open mysql port 3306 under linux
How to open mysql port 3306 under linux
1. First, enter the console. The picture below shows me using putty tool to realize remote control. Then enter "netstat -an | grep 3306" to see if it is turned on. As shown in the figure below, only listen is displayed, which means it is not opened.

2. Then enter the etc/mysql directory through the cd command. Then enter the ls command to view the files in this directory.

3. You will see my.cnf in the file. Enter the editing state through the "vi my.cnf" command.

4. After that, put "bind-address? = 127.0.0. 1 "Comment out or replace it with an ip address that requires remote connection, or simply delete this sentence before saving.