I just solved my problem, thanks for your help!
I'm a developer who wants to connect to the aurora serverless (mysql) through the ec2 instance using ProxySQL.
The ec2 instance is running on Amazon Linux 2.
I tried to connect from my computer using this command.
mysql -u<username> -p<password> -h <my instance's public address> -P6033
but kept getting this error.
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 2003 (HY000): Can't connect to MySQL server on '<my address>' (110)
So I tried to check all the settings that can block connecting to the server, and here are the links I pasted the results.
- netstat -nlt from the server : https://pastebin.com/m5tkX2kf
- ProxySQL's variable settings : https://pastebin.com/MNJLHFQt
- AWS Security Group settings : https://pastebin.com/EX4WtKtQ
- AWS Network ACL settings : https://pastebin.com/Re3MEs4Q
- Result of using namp from my computer : https://pastebin.com/zStYLEsA
But still can't find why I can't connect from my desktop.
Could you tell me why I can't connect and what I have to do? I really appreciate it if you let me know how to fix it.
Many thanks!