LoginSignup
2
3

More than 5 years have passed since last update.

MySQLのリモートアクセスができない時

Posted at

サーバにあるMySQLに対してローカルからリモートアクセスしようとした時のメモ。
ポートの確認・設定には触れていません。

環境

CentOS Linux release 7.3.1611
MySQL MariaDB 5.5.52

設定手順

bind-addressの確認
$ netstat -antで確認すると「127.0.0.1:3306」でLISTENされている。
これを「0.0.0.0:3306」に変更する。

bind-addressの設定
/etc/my.cnfに「bind-address」の項目がある。
これをコメントアウト。

mariadbをリスタート
$ systemctl restart mariadb.serviceで再起動

2
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
3