简体   繁体   English

将 SQL 开发人员与在 EC2 中的 Docker 容器上运行的 MYSQL 服务器连接

[英]Connect SQL developer with MYSQL server running on Docker container in EC2

Could you please guide me How can I connect my local SQL developer to MY SQL Server running on Docker container in EC2.请指导我如何将我的本地 SQL 开发人员连接到我的 SQL 服务器上运行在 EC2 中的 Docker 容器上。 But I havent installed mysql in my ec2 host.但我还没有在我的 ec2 主机中安装 mysql。

I have tried with public dns and port 3306 but getting below error我已经尝试使用公共 dns 和端口 3306 但低于错误

An error occurred while establishing the connection:

`Long Message: Communications link failure `长消息:通信链路故障

The last packet successfully received from the server was 353 milliseconds ago.从服务器成功接收到的最后一个数据包是 353 毫秒前。 The last packet sent successfully to the server was 339 milliseconds ago.最后一个成功发送到服务器的数据包是在 339 毫秒前。

Details: Type: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException SQL State: 08S01` Details: Type: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException SQL State: 08S01`

follow the guide in this official AWS documentation遵循此官方 AWS 文档中的指南

https://aws.amazon.com/premiumsupport/knowledge-center/connect-http-https-ec2/ https://aws.amazon.com/premiumsupport/knowledge-center/connect-http-https-ec2/

Use port 3306 however, this is a guide for webservers但是,请使用端口 3306,这是网络服务器的指南

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM