From: Avleen Vig (lists-sunmanagers@silverwraith.com)
Date: Thu Dec 05 2002 - 22:30:34 EST
Environment: Solaris 2.6 and 2.8
I have an application that listens on the network and spawns a new child
for each network connection.
I need to find a fast way to map each connecting IP to the PID of the
child that was spawned.
At first I thought 'lsof' would be ideal, but it takes far too long.
For each IP I give it, it takes up to 8 seconds to respond. The -C flag
can knock maybe a second off this, but that's still slow.
Ideally it wouldn't take more than a second or three to respond will all
the PIDs (there can be multiple connections thus multiple children).
Does anyone know how else I can achieve the results I want?
Linux netstat has the '-p' flag which does this :-(
-- Avleen Vig: Work Time: Unix Systems Admin Email: work@silverwraith.com Play Time: Network Security Admin Pager: av-pager, at silverwraith com Smurf Amplifier Finding Executive: http://www.ircnetops.org/smurf _______________________________________________ sunmanagers mailing list sunmanagers@sunmanagers.org http://www.sunmanagers.org/mailman/listinfo/sunmanagers
This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:25:25 EDT