Answer the question
In order to leave comments, you need to log in
How to find MySQL server address?
Good evening!
I installed on my VPS (Ubuntu) MySQL-server.
In the settings, I commented out the line from which IP addresses you can connect to the server. Now you can connect from anywhere.
Can you please tell me how can I find the server address to connect to?
Answer the question
In order to leave comments, you need to log in
Hmm, well, advice.
See what mysql is listening on, if there is no Internet connection, see what socket it uses
[08:43] ~ (dcn01srv056)
$ netstat -nlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 31555/mysqld
tcp 0 0 127.0.0.1:49002 0.0.0.0:* LISTEN 3264/uwsgi
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 2774/nginx
Em.
By default, MySQL only allows connections from the localhost address.
make ifconfig on the server and look at the IP address.
And I want to add right away that "commenting out the line in the config" is not enough to connect from remote servers. You need to create a user in MySQL indicating that he can connect not only from localhost webew.ru/articles/414.webew
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question