To show what ports are open from ssh run this command
netstat -na | grep 'tcp\|udp' | awk '{print $4}' | cut -d: -f2 | sort | uniq -c | awk '{print $2}'
To show what ports are open from ssh run this command
netstat -na | grep 'tcp\|udp' | awk '{print $4}' | cut -d: -f2 | sort | uniq -c | awk '{print $2}'