*BSD News Article 34961


Return to BSD News archive

Xref: sserve comp.unix.sys5.r4:8207 comp.unix.bsd:14716 comp.unix.aix:43098 comp.sys.hp.hpux:11061 comp.protocols.tcp-ip:31279
Path: sserve!newshost.anu.edu.au!harbinger.cc.monash.edu.au!yeshua.marcam.com!MathWorks.Com!panix!not-for-mail
From: berke@panix.com (Wayne Berke)
Newsgroups: comp.unix.sys5.r4,comp.unix.bsd,comp.unix.aix,comp.sys.hp.hpux,comp.protocols.tcp-ip
Subject: Re: sock to proc?
Date: 26 Aug 1994 11:44:53 -0400
Organization: Nalgame Dios, Ltd.
Lines: 13
Message-ID: <33l2ll$lna@panix.com>
References: <33jc7q$3gk@news.cerf.net> <33k9uq$31g@u.cc.utah.edu>

In <33k9uq$31g@u.cc.utah.edu> terry@cs.weber.edu (Terry Lambert) writes:

>In article <33jc7q$3gk@news.cerf.net> escneto@cerfnet.com writes:
>] Question.  Given a pointer to a socket in the kernels address space, how
>] can I go about finding the process which owns the socket?

>What do you mean "a pointer to a socket in the kernels address space".

If by any chance you can get a pointer to the pcb block (first field of the
netstat -A output), you can use lsof to match up the associated process.
-- 
Wayne Berke
berke@panix.com