By marcusr1
I’m connecting to my droplet fine on localhost, which proves that the IP, port, user and pw are correct, but when I load the same php code to a server that is supposed to connect to my DO database, I get:
PHP Fatal error: Uncaught mysqli_sql_exception: Connection timed out
Can anyone help me? this article doesn’t help becasue I can’t see the Control Panel (I have CLI) https://docs.digitalocean.com/products/databases/mysql/how-to/secure/#firewalls
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
If you are using a Managed MySQL database cluster there are a few things that you need to make sure that you have in place:
25060
as your port in your connection string25060
for outgoing TCP connections so that the Droplet can connect to the MySQL clusterLet me know how it goes!
- Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.