无法将MySQL Workbench连接到RDS实例 [英] Unable to connect MySQL Workbench to RDS instance
问题描述
创建新的服务器实例以连接到RDS数据库时,我无法测试数据库连接. 它说Bad_Authentication [allowed_types = public_key],我尝试了不同的.pem文件,并且通过很多论坛来做. 我还允许在RDS的数据库安全组和EC2的安全组中访问我的IP.
I am not able to Test DB Connection while creating new server instance to connect to the RDS database. It says Bad_Authentication[allowed_types=public_key], i have a tried different .pem files and have done through a lot of forums. I have also allowed access to my IP in the DB SecurityGroups for RDS and the Security Groups for EC2.
请帮帮我.谢谢.
推荐答案
这对我有用.假设您已登录到AWS:
This worked for me. Assuming you have logged into AWS:
- 转到RDS->数据库->选择数据库
-
确保公共可访问性值为是
使用 http://checkip.amazonaws.com/检查您的IP地址.如果未将其添加到安全规则组"中,则应添加它. 此步骤至关重要
Check your IP address using http://checkip.amazonaws.com/. If it is not added to the Security Rule Groups, you should add it. this step is crucial
3.1.单击规则名称.这将打开一个新标签,然后单击规则名称.
3.1. Click on the rule name. This will open up a new tab, then click in the name of the rule.
3.2.点击编辑入站规则
3.3.单击添加新规则,然后添加具有以下值的规则:
3.3. Click on Add new rule, and add a rule with the following values:
类型: MYSQL/Aurora.
Type: MYSQL/Aurora.
协议:TCP(默认)
端口范围: 3306(默认)
来源:我的IP->这将是您在 http:/上获得的IP地址./checkip.amazonaws.com/.
Source: My IP -> This will be the IP Address you got at http://checkip.amazonaws.com/.
- 在MySQL Workbench中填充信息
主机名:使用您在连接性和安全性"上为Endpoint拥有的值
Hostname: Use the value you have for Endpoint at Connectivity and Security
端口:使用连接性和安全性"中端口"的值,默认值为3306.
Port: Use the value you have for Port at Connectivity and Security, by default it is 3306.
用户名:使用配置中的主用户名的值
Username: Use the value you have for master username at Configuration
密码:使用您在创建数据库实例时设置的值.
Password: Use the value you set when you created the database instance.
如果您忘记了密码,则可以通过在数据库实例中单击修改"来更改它.
If you forgot the password, you can change it by clicking on Modify in your database instance)
我希望这对您也有帮助.
I hope this also helps for you.
这篇关于无法将MySQL Workbench连接到RDS实例的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!