Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!elroy.jpl.nasa.gov!lll-winken!ames!sgi!calcite!vjs From: vjs@calcite.UUCP (Vernon Schryver) Newsgroups: comp.unix.sysv386 Subject: Re: Getting process names from sockets Summary: maybe fuser Message-ID: <116@calcite.UUCP> Date: 8 Jun 91 17:20:11 GMT References: <1991Jun7.184121.29105@garfield.cs.mun.ca> Organization: Rhyolite Software, Mountain View, CA Lines: 16 In article <1991Jun7.184121.29105@garfield.cs.mun.ca>, glenn8@garfield.cs.mun.ca (Glenn Stowe) writes: > We are running 386/ix with Berkley extensions (sockets, etc.) and would like > to be able to determine, given an active socket number or PCB, what processes > are connected by that socket. Fstat and Ofiles will do this on SunOS or Bsd >but the facility desn't seem to be there for SysV. Does anybody have any ideas? At least one workstation vendor shipping SVR3 with 4.3BSD-tahoe TCP/IP has extended the SV fuser command for just this purpose. A "path" of the form 'port/protocol' or 'hostname:port:protocol' which does specify a valid file is understood to be a request to list processes with the sockets connected to the specified port. 'Port' must be an integer constant, and 'protocol' must be either TCP or UDP. 'Hostname' must be a IP number or hostname, and is used to specify individual connections. Vernon Schryver, vjs@calcite.uucp