PHP connection to remote AWS MySQL RDS

I have a client using a MySQL database on Amazon Web Services RDS. I need to connect to that database from my own shared hosting server on I have been able to connect from my desktop successfully using MySQL Workbench and have created a php connection script in Workbench. However, my connection is being rejected with the following error:
mysqli::mysqli(): (HY000/2003): Can't connect to MySQL server on '' (110)

Open in new window

The user privileges are set to accept connection from host %.

I have avoided using AWS in the past as they seem to have reinvented the wheel in hosting administration. Nothing, and I mean nothing, in the AWS control panel even resembles anything I've ever used before. Even the terminology is unfamiliar. Even though I've set up dozens on databases for remote and local access, I am in unfamiliar territory with this system.

Any suggestions?
LVL 22
Kim WalkerWeb Programmer/TechnicianAsked:
Who is Participating?
Dave BaldwinConnect With a Mentor Fixer of ProblemsCommented:
You should first verify that NameCheap allows you to connect to external databases.  Some hosts do not allow that.
Phil PhillipsDirector of DevOps & Quality AssuranceCommented:
Some other things to check on the AWS side:

  1. Your endpoint resolves to a public IP address (just verifies that RDS was set up with an external IP)
  2. The "Security Group" tied to your RDS instance allows port 3306 from the outside
  3. The subnet that the RDS instance is placed in has a route with an internet gateway
Kim WalkerWeb Programmer/TechnicianAuthor Commented:
That was it Dave. All I had to do was ask for it the port to be opened.
Dave BaldwinFixer of ProblemsCommented:
You're welcome, glad to help.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.