source

MariaDB가 0.0.0에서 리슨하지 않음

manysource 2022. 10. 15. 10:01

MariaDB가 0.0.0에서 리슨하지 않음

Ubuntu 16.04를 실행하고 있는 VPS의 MariaDB/MySQL 버전은 다음과 같습니다.mysql Ver 15.1 Distrib 10.0.29-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

이것은 아마도 의 관련 내용일 것이다./etc/mysql/mariadb.conf.d/50-server.cnf:

  1 #
  2 # These groups are read by MariaDB server.
  3 # Use it for options that only the server (but not clients) should see
  4 #
  5 # See the examples of server my.cnf files in /usr/share/mysql/
  6 #
  7 
  8 # this is read by the standalone daemon and embedded servers
  9 [server]
 10 
 11 # this is only for the mysqld standalone daemon
 12 [mysqld]
 13 
 14 #
 15 # * Basic Settings
 16 #
 17 user    = mysql
 18 pid-file  = /var/run/mysqld/mysqld.pid
 19 socket    = /var/run/mysqld/mysqld.sock
 20 port    = 3306
 21 basedir   = /usr
 22 datadir   = /var/lib/mysql
 23 tmpdir    = /tmp
 24 lc-messages-dir = /usr/share/mysql
 25 skip-external-locking
 26 
 27 # Instead of skip-networking the default is now to listen only on
 28 # localhost which is more compatible and is not less secure.
 29 bind-address    = 0.0.0.0 #This is line changed by me from 127.0.0.1
 30 

사용 후systemctl stop mysql그리고.systemctl start mysql이것은 여전히 나의 것이다.netstat -nat |grep :3306의 출력:

tcp        0      0 127.0.0.1:3306          0.0.0.0:*               LISTEN     
tcp        0      0 127.0.0.1:3306          127.0.0.1:54316         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58456         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58466         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58458         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58454         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58460         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58444         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58452         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58446         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58462         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58464         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58450         ESTABLISHED
tcp        0      0 127.0.0.1:3306          127.0.0.1:58468         ESTABLISHED

첫 번째 줄에서 볼 수 있듯이, 여전히 듣고 있습니다.127.0.0.1, on이 아닌 경우0.0.0.0내가 어디가 잘못됐을까?TIA

언급URL : https://stackoverflow.com/questions/43143302/mariadb-not-listening-on-0-0-0-0