使用工作台或其他mysql实用程序无需密钥即可远程连接到AWS RDS [英] Connecting to AWS RDS remotely without key using workbench or other mysql utilities

查看:35
本文介绍了使用工作台或其他mysql实用程序无需密钥即可远程连接到AWS RDS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何远程连接AWS中的MySQL RDS实例?

How to connect with MySQL RDS instance in AWS remotely?

当我使用标准(TCP/IP)连接时,它始终抛出以下错误:

It keeps throwing the following error when I connect with Standard (TCP/IP):

错误2003(HY000):无法连接到"xxxxxxx.yyyyyyyyy.us-west-2.rds.amazonaws.com"上的MySQL服务器(10060未知错误")

ERROR 2003 (HY000): Can't connect to MySQL server on 'xxxxxxx.yyyyyyyyy.us-west-2.rds.amazonaws.com' (10060 "Unknown error")

尝试过 Workbench MySQL Utilities .但是,当使用基于SSH的标准TCP/IP 时,当我添加.pem密钥文件时,我可以连接到实例.

Tried with Workbench and MySQL Utilities. However, when using Standard TCP/IP over SSH, when I add .pem key file, I could connect to the instance.

推荐答案

存在无法连接的各种问题:

There are various problems why it cannot be connected:

  • 安全组:

RDS实例的RDS安全组需要配置为允许从您的IP地址进行访问.一旦完成,您就可以通过运行telnet 3306来验证您是否具有良好的连接性.一旦可以正常连接,那么我应该可以使用MySQLWorkbench进行连接. [回答,由slucedbylucifer ]

The RDS Security Group for the RDS instance needs to be configured to allow access from your IP address. Once it is done, then you can verify that you have GOOD connectivity by running telnet 3306. Once you are able to connect fine, then I should be able to connect using MySQLWorkbench. [Answered by slayedbylucifer]

  • 防火墙

检查个人计算机所在网络的防火墙中打开了哪些传出端口.即使RDS实例允许所有流量,防火墙也可能阻止您建立连接. [回答,由vijrox ]

Check what outgoing ports are open in the firewall on the network your personal computer is on. Even though the the RDS Instance allows for all traffic, your firewall may be blocking you from making the connection. [Answered by vijrox]

  • 公众可访问:

检查实例的安全性参数-可公开访问是否设置为.否则,即使所有安全组配置正确并且端口可用于连接,该实例仍然不可用.如果禁用了可公开访问的选项,则可以通过以下方式启用它:

Check if the security parameter of the instance - Publicly Accessible is set to Yes. Otherwise, even though all security group is configured well and port is available for connection the instance remains unavailable. If publicly accessible option is disabled, it can be enabled by:

  1. 创建该实例的快照.
  2. 从该快照中启动新实例,并将可公开访问"选项设置为.

这篇关于使用工作台或其他mysql实用程序无需密钥即可远程连接到AWS RDS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆