Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 03-09-2007, 02:34 AM   #1
Registered: Oct 2003
Posts: 78

Rep: Reputation: 15
pid in netstat command on solaris


On RH linux if I give following command,

$ netstat -atnp

it shows the pid/program name (option -p).

But, what is the netstat option(similar to -p) on solaris to view the pid or program name of the process listening on particular socket?

Old 03-10-2007, 01:52 AM   #2
Registered: Dec 2003
Distribution: Debian, FreeBSD
Posts: 310

Rep: Reputation: 35
You should be able to use lsof.

lsof -i tcp:22

I seem to remember another way to do this on Solaris, but can't think of it at the moment.

Unless something has changed with recent versions of the Solaris netstat command there is not a similar -p option.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Netstat command Panagiotis_IOA Linux - Networking 2 03-13-2006 12:56 PM
where to get source code for netstat command Madhusudhan Linux - Software 1 02-09-2006 01:48 AM
question netstat command nick623 Linux - Newbie 2 01-31-2005 07:53 PM
netstat -r command output juanb Linux - Networking 1 10-28-2004 02:30 PM
Netstat command scottpioso Linux - Networking 14 09-06-2003 10:06 AM

All times are GMT -5. The time now is 06:42 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration