open ports /sockets in hp unix :How to check??

To check the open ports

netstat -an | grep -i listen
netstat -an | grep <port number>


To find  out the files which is using particular protocol on ports

lsof -i :"port no"

Example : lsof -i :513

To find out the process which is using particular ports

lsof -nP -i "port no"

Example : lsof -nP -i tcp:2100

Post a Comment

0 Comments