Operating System - HP-UX
1836655 Members
2111 Online
110102 Solutions
New Discussion

How can I tell what process is using a particular port?

 
SOLVED
Go to solution
Karen Elrod
Frequent Advisor

How can I tell what process is using a particular port?

HPUX 10.20
Netstat -a lists active port, how can I tell what process is tied to it.
I have a port that is tied up by something using a wrong port number. I have used netstat to see that it is active:
tcp 0 0 dixie.50680 *.* LISTEN
Thanks
Karen
6 REPLIES 6
Erich Noll_1
Occasional Advisor

Re: How can I tell what process is using a particular port?

There's a shareware product called lsof I've used to do this before.
"It's better to remain silent and be thought a fool than to speak and remove all doubt" - Samuel Clemens
Kofi ARTHIABAH
Honored Contributor

Re: How can I tell what process is using a particular port?

Check the thread:

http://my1.itrc.hp.com/cm/QuestionAnswer/1,1150,0xb14268c57f64d4118fee0090279cd0f9,00.html

you need to get and install lsof from the porting centre
nothing wrong with me that a few lines of code cannot fix!
CHRIS_ANORUO
Honored Contributor

Re: How can I tell what process is using a particular port?

Download lsof from HP-UX Porting Site at:http://hpux.cs.utah.edu/hppd/hpux/Sysadmin/lsof-4.48/
When We Seek To Discover The Best In Others, We Somehow Bring Out The Best In Ourselves.
Rita C Workman
Honored Contributor
Solution

Re: How can I tell what process is using a particular port?

The command netstat -an will give you a little more of what your looking for....BUT you will find that getting and using lsof is more preferred.
Here's where you can find it:
LSOF can be dowloaded using the following procedure:

1. Go to www.software.hp.com
2. Scroll down to the end and follow the link "HPUX Public Domain Software"
3. Type lsof into the search field and click search.
4. Download the current version of lsof

Anthony Goonetilleke
Esteemed Contributor

Re: How can I tell what process is using a particular port?

you can also get it from the original source the advantage is that you can get the latest version and compile it to suit you.

ftp://vic.cc.purdue.edu/pub/tools/unix/lsof/
Minimum effort maximum output!
S.Venkatesh
Occasional Advisor

Re: How can I tell what process is using a particular port?

Download lsof, I got the same suggestion.