View previous topic :: View next topic |
Author |
Message |
MrPyro Tux's lil' helper
Joined: 14 Aug 2003 Posts: 121 Location: Sheffield, England
|
Posted: Mon Aug 18, 2003 1:13 pm Post subject: Use of netstat on a gateway |
|
|
I have a network set up, where all the computers (running a mix of Windows 98/2000 and Linux) route through a gateway runnning Gentoo. The Gentoo server is running an iptables NAT firewall to masquerade all the addresses to the outside world.
Does anybody know of a way to use netstat or another net tracking tool to see what connections are being routed through the gateway? Netstat with no options seems to only show the conections the gateway itself is making, not what the workstations in the lab are connecting to. I tried the -M option (which the man page says "displays a list of masqueraded connections"), but it just prints an error saying
Code: |
netstat: no support for 'ip_masquerade' on this system
|
Given that the NAT firewall is running perfectly and has been for several months, I assume all appropriate kernel options are activated, so I don't know why it tells me I have no support.
If somebody knows of a better netstat option to use (I read the man page but none jumped out at me), or can suggest a better tool (with no GUI, as I'm running an X-less server), I would be very grateful. _________________ Back off man, I'm a computer scientist |
|
Back to top |
|
|
devon l33t
Joined: 23 Jun 2003 Posts: 943
|
Posted: Mon Aug 18, 2003 3:04 pm Post subject: |
|
|
What about using /proc/net/ip_conntrack? You'll probably have to write a basic script to make it pretty. |
|
Back to top |
|
|
MrPyro Tux's lil' helper
Joined: 14 Aug 2003 Posts: 121 Location: Sheffield, England
|
Posted: Mon Aug 18, 2003 3:15 pm Post subject: |
|
|
Good lord, that is an ugly file, isn't it?
Looks like its got all the info I need though: just need to decrypt it and make it look nice.
Cheers for the pointer, devon. _________________ Back off man, I'm a computer scientist |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|