How to open a port

0

Hello,

I just setup a lightsail Centos 8 instance and also installed firewalld. I am trying to open port 3306 for MySQL.

I did the following commands and each time got a success response:

sudo firewall-cmd --zone=public --permanent --add-port=3306/tcp sudo firewall-cmd --reload

sudo firewall-cmd --zone=public --permanent ----add-service=mysql sudo firewall-cmd --reload

Online open port checker, https://www.yougetsignal.com/tools/open-ports/ shows its closed.

Been self-hosting this database for several months from my home CentOS 8 server but wanted to move it somewhere for reliability.

Any help or suggestions would be greatly appreciated!

TIA

preguntada hace 2 años727 visualizaciones
2 Respuestas
2

It sounds like you opened the port on the local firewall daemon but it's being blocked at another level. Did you ensure the AWS security group is allowing the connection as well? Here's some more information on Amazon EC2 Instance security groups. They act as a virtual firewall for your EC2 instances to control incoming and outgoing traffic so there could be a hang up there as well. It might also be worth looking into the VPC Reachability Analyzer which is a configuration analysis tool that enables you to perform connectivity testing between a source resource and a destination resource in your virtual private clouds. It will produce a hop-by-hop map of the virtual network path between the source and the destination. When the destination is not reachable, Reachability Analyzer identifies the blocking component. And of course, if all else fails, I'd recommend you open a Support case with Amazon Support, if none of the above works, they'll be able to quickly get you sorted.

AWS
AWSJoe
respondido hace 2 años
0

I figured it out. Have to open from the networking tab.

respondido hace 2 años

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas