The following command you can use to open a port to if you are getting a connection refused error on specific port number :
iptables -A INPUT -p tcp --dport <Port>2 -j ACCEPT
iptables -A INPUT -p tcp --dport <Port>2 -j ACCEPT
Open and listening ports :
netstat -anltp | grep "LISTEN"
Established ports :netstat -anltp | grep "ESTABLISHED"
WINDOWS TROUBLESHOOTING · FULL GUIDE Unlock Hidden Windows Startup and Shutdown Details Enable Verbose Status...