Search code examples
amazon-web-servicesrdsopenvpn

VPN connection to Amazon RDS with openvpn suddenly fails


I set AWS Client VPN Endpoint, and downloaded opvn file, configured it to refer to cert/key files and connected to AWS RDS.

It used to success connecting yesterday, but today, after re-installing ESET security app

It shows the following error when I trying connecting with MySQL client app:

ERROR 2005 (HY000): Unknown MySQL server host 'myrds.something.ap-northeast-1.rds.amazonaws.com' (0)

I am not sure how to detect the cause of the error. If I configured RDS settings to pubilc, the error above not shown and just waiting for minutes...

(maybe I guess some DNS settings overriden by ESET? )


Solution

  • You can easily debug the problem:

    1. AWS Client VPN Endpoint, You can see the active connection. See if you are connected to it or not.

    2. Do you restarted or reinstall RDS also, Because it will change the URL to connect.

    3. Is username/password of DB is changed.

    4. If RDS is in public setting you don't even need a VPN connection.

    5. Also as suggested above check VPN to RDS VPC Route.

    Thanks,

    AB