[lug] Setting up a running list of IP masqerade entries...

John Hernandez John.Hernandez at noaa.gov
Thu Mar 8 16:02:13 MST 2001


> "celttechie (Brian Jarrett)" wrote:
> 
> Hello all,
> 
> I am able to run ipchains from an ssh session to view current masqueraded connections.  I'm wondering if there is already something created, or how I might go about creating a solution, to show these connections in real time over the ssh terminal.
> 
> Does anyone have any ideas?  Even something similar to the output of tail would be OK, although I don't think it would update the list, only show new connections being made.
> 
> TIA,
> Brian Jarrett

For a crude version, write a quick script:

infinite loop (blank the terminal, cat /proc/net/ip_masquerade, sleep 10)

Another idea could be to set kernel parameter /proc/sys/net/ipv4/ip_masq_debug to 1 and research how to capture/parse the output.

-John



More information about the LUG mailing list