How to get one process’s port number?

If we want to check one program on one remote server, we need to know this server’s IP and port number. How to get this program’s port number in the remote server?

# netstat -tulpn

Remember to run this program with root permission since some programs can only be accessed by root.

Answered by harryxiyou.

Weiwei Jia

Weiwei Jia is a Ph.D. student in the Department of Computer Science at New Jersey Institute of Technology since 2016. His research interests are include storage systems, operating systems and computer systems.

Leave a Reply

Your email address will not be published. Required fields are marked *