AWS RDS数据库显示超时错误

编程入门 行业动态 更新时间:2024-10-28 12:22:53
本文介绍了AWS RDS数据库显示超时错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

从EC2实例访问RDS时,该时间显示超时错误

When accessing RDS from an EC2 instance that time show me timeout error

Fatal error: Uncaught PDOException: SQLSTATE[HY000] [2002] Connection timed out in

我尝试指定EC2实例的IP地址并指定RDS实例的内部IP,但是错误相同.

i have try to specifying the IP address of the EC2 instance and specify the internal IP of the RDS instance but error is same.

推荐答案

最可能的原因是您的RDS安全组未配置为允许传入流量.

The most probable reason is that your RDS Security Groups are not configured to allow incoming traffic.

您需要更改这些安全组并允许入站流量.

You need to change those security groups and allow inbound traffic.

建议将入站流量的源IP限制为您要从中命中RDS的EC2实例的内部IP,或仅限于在其中创建EC2实例的VPC/子网的CIDR块.

Would recommend that inbound traffic's source IP's be limited to internal IP's of the EC2 instances from which you are hitting the RDS or for the CIDR block of the VPC/Subnet in which your EC2 instances are created.

更多推荐

AWS RDS数据库显示超时错误

本文发布于:2023-10-17 12:44:25,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1500933.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:错误   数据库   AWS   RDS

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!