Re: measure throughput?
From: Jose Maria Lopez Hernandez (jkerouac_at_bgsec.com)
Date: 03/31/05
- Next message: Stefan Lindecke: "routing ports from special PCs to another gateway"
- Previous message: Jose Maria Lopez Hernandez: "Re: simple question about ip_forward and NAT routing."
- In reply to: linuxnooby: "Re: measure throughput?"
- Next in thread: Christian Reiter: "Re: measure throughput?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 31 Mar 2005 11:00:26 +0200
linuxnooby wrote:
> Thanks Jose
>
> what does this look like (assuming eth0 is outside interface)??
> also how do i view the counters??
>
>
> iptables -N DOWNLOADS
> iptables -A INPUT -i eth0 -j DOWNLOADS
> iptables -A FORWARD -i eth0 -j DOWNLOADS
> iptables -A DOWNLOADS -j RETURN
>
> iptables -N UPLOADS
> iptables -A OUTPUT -o eth0 -j UPLOADS
> iptables -A FORWARD -0 eth0 -j UPLOADS
> iptables -A UPLOADS -j RETURN
Yes, that's what I do. Then you can use iptables -L UPLOADS -xvn
to get the counters and you can use bash or perl to extract the
counters from the output of iptables.
If you are gonna use a lot of this kind of chains and you want
to check a lot of counters you better use a C program using
libiptc to check the counters, or it will be very slow.
> thanks
> Dave
Regards.
-- Jose Maria Lopez Hernandez Director Tecnico de bgSEC jkerouac@bgsec.com bgSEC Seguridad y Consultoria de Sistemas Informaticos http://www.bgsec.com ESPAŅA The only people for me are the mad ones -- the ones who are mad to live, mad to talk, mad to be saved, desirous of everything at the same time, the ones who never yawn or say a commonplace thing, but burn, burn, burn like fabulous yellow Roman candles. -- Jack Kerouac, "On the Road"
- Next message: Stefan Lindecke: "routing ports from special PCs to another gateway"
- Previous message: Jose Maria Lopez Hernandez: "Re: simple question about ip_forward and NAT routing."
- In reply to: linuxnooby: "Re: measure throughput?"
- Next in thread: Christian Reiter: "Re: measure throughput?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|