Reputation: 794
I have a fixed IP attached to my EC2 instance. I am able to test the connection with nc as follows.
$ nc -v **.***.***.** 3306
Ncat: Version 6.25 ( http://nmap.org/ncat )
Ncat: Connection refused.
But,
$ nc -v **.***.***.** 22
Ncat: Version 6.25 ( http://nmap.org/ncat )
Ncat: Connected to **.***.***.**.
SSH-2.0-OpenSSH_5.9p1 Debian-5ubuntu1
In my security group I have two rules:
1) Inbound 22 from 0.0.0.0/0
2) Inbound 3306 from 0.0.0.0/0
What am I missing?
Upvotes: 2
Views: 1076
Reputation: 794
Ok, I found that answer to this.
I was under the impression that in /etc/mysql/my.cnf
, I simply had to comment skip-networking
(which does not appear in MySQL my.cnf past a certain version). Turns out you also have to comment out #bind-address = 127.0.0.1
.
nc threw me off, I thought the problem was at the firewall. I'll still be happy to accept as a correct answer anyone who can shed light on what bind-address
achieves.
Thanks.
Upvotes: 1