0

I just open a port in the server using the below command and suddenly putty connection fails for everyone.

This happens every time when I open a port. I think something is wrong with my command used to open the port.

sudo ufw allow 5700 - I use this for opening any port, I think the syntax is only for opening ssh port and not other ports, Please correct me and in the future, I can use proper syntax

P.S. ssh keys are set to No, password authentication to Yes

Thank you all,

Edit 1: ufw status output

To Action From


4675 ALLOW Anywhere

4675/tcp ALLOW Anywhere

23 ALLOW Anywhere

23/tcp ALLOW Anywhere

8443/tcp ALLOW Anywhere

22/tcp ALLOW Anywhere

80/tcp ALLOW Anywhere

443/tcp ALLOW Anywhere

11211 ALLOW Anywhere

8080/tcp ALLOW Anywhere

9503/tcp ALLOW Anywhere

9502/tcp ALLOW Anywhere

9501/tcp ALLOW Anywhere

9500/tcp ALLOW Anywhere

3500/tcp ALLOW Anywhere

3503/tcp ALLOW Anywhere

3502/tcp ALLOW Anywhere

9506/tcp ALLOW Anywhere

1992/tcp ALLOW Anywhere

8762/tcp ALLOW Anywhere

8083/tcp ALLOW Anywhere

1998/tcp ALLOW Anywhere

9251/tcp ALLOW Anywhere

9252/tcp ALLOW Anywhere

3423/tcp ALLOW Anywhere

6379 ALLOW Anywhere

3282/tcp ALLOW Anywhere

3000/tcp ALLOW Anywhere

9238/tcp ALLOW Anywhere

1991/tcp ALLOW Anywhere

5550/tcp ALLOW Anywhere

1993/tcp ALLOW Anywhere

61616/tcp ALLOW Anywhere

8181/tcp ALLOW Anywhere

8161/tcp ALLOW Anywhere

1995/tcp ALLOW Anywhere

9327/tcp ALLOW Anywhere

1999/tcp ALLOW Anywhere

1997/tcp ALLOW Anywhere

2003/tcp ALLOW Anywhere

7340/tcp ALLOW Anywhere

8084/tcp ALLOW Anywhere

3001/tcp ALLOW Anywhere

27017/tcp ALLOW Anywhere

7748/tcp ALLOW Anywhere

5600 ALLOW Anywhere

5601 ALLOW Anywhere

5601/tcp ALLOW Anywhere

5600/tcp ALLOW Anywhere

4675 (v6) ALLOW Anywhere (v6)

4675/tcp (v6) ALLOW Anywhere (v6)

23 (v6) ALLOW Anywhere (v6)

23/tcp (v6) ALLOW Anywhere (v6)

8443/tcp (v6) ALLOW Anywhere (v6)

22/tcp (v6) ALLOW Anywhere (v6)

80/tcp (v6) ALLOW Anywhere (v6)

443/tcp (v6) ALLOW Anywhere (v6)

11211 (v6) ALLOW Anywhere (v6)

8080/tcp (v6) ALLOW Anywhere (v6)

9503/tcp (v6) ALLOW Anywhere (v6)

9502/tcp (v6) ALLOW Anywhere (v6)

9501/tcp (v6) ALLOW Anywhere (v6)

9500/tcp (v6) ALLOW Anywhere (v6)

3500/tcp (v6) ALLOW Anywhere (v6)

3503/tcp (v6) ALLOW Anywhere (v6)

3502/tcp (v6) ALLOW Anywhere (v6)

9506/tcp (v6) ALLOW Anywhere (v6)

1992/tcp (v6) ALLOW Anywhere (v6)

8762/tcp (v6) ALLOW Anywhere (v6)

8083/tcp (v6) ALLOW Anywhere (v6)

1998/tcp (v6) ALLOW Anywhere (v6)

9251/tcp (v6) ALLOW Anywhere (v6)

9252/tcp (v6) ALLOW Anywhere (v6)

3423/tcp (v6) ALLOW Anywhere (v6)

6379 (v6) ALLOW Anywhere (v6)

3282/tcp (v6) ALLOW Anywhere (v6)

3000/tcp (v6) ALLOW Anywhere (v6)

9238/tcp (v6) ALLOW Anywhere (v6)

1991/tcp (v6) ALLOW Anywhere (v6)

5550/tcp (v6) ALLOW Anywhere (v6)

1993/tcp (v6) ALLOW Anywhere (v6)

61616/tcp (v6) ALLOW Anywhere (v6)

8181/tcp (v6) ALLOW Anywhere (v6)

8161/tcp (v6) ALLOW Anywhere (v6)

1995/tcp (v6) ALLOW Anywhere (v6)

9327/tcp (v6) ALLOW Anywhere (v6)

1999/tcp (v6) ALLOW Anywhere (v6)

1997/tcp (v6) ALLOW Anywhere (v6)

2003/tcp (v6) ALLOW Anywhere (v6)

7340/tcp (v6) ALLOW Anywhere (v6)

8084/tcp (v6) ALLOW Anywhere (v6)

3001/tcp (v6) ALLOW Anywhere (v6)

27017/tcp (v6) ALLOW Anywhere (v6)

7748/tcp (v6) ALLOW Anywhere (v6)

5600 (v6) ALLOW Anywhere (v6)

5601 (v6) ALLOW Anywhere (v6)

5601/tcp (v6) ALLOW Anywhere (v6)

5600/tcp (v6) ALLOW Anywhere (v6)

2
  • 2
    Did you also allow SSH before enabling ufw? Please edit your question to show the output of sudo ufw status – steeldriver Nov 17 '20 at 14:07
  • yes ssh was allowed before enabling ufw and for e.g., I run sudo ufw allow 5700, that's it ssh to the (GCP)server fails, sometimes need to reboot the server or just wait for 4-5 hrs, and then it works. – Manoj Nov 18 '20 at 4:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.