OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
Re: low network throughput

From: Hugo de Paix de Coeur (hugokabhal.dyndns.org)
Date: Mon Jan 03 2005 - 06:23:25 CST


On Mon, Jan 03, 2005 at 05:13:28AM +0000, Stephen Marley wrote:
> On Mon, Jan 03, 2005 at 04:01:59AM +0100, Hugo de Paix de Coeur wrote:
> > Hi,
> >
> > I've OpenBSD 3.5 on a Pentium 133 box (RAM: 32 Mo), a netgear 100BTX full-duplex netcard FA330 (sis driver).
> > I tested my network throughput with netperf and get that for TCP_STREAM:
> >
> > amonite> netperf -H sungate -l 60
> > TCP STREAM TEST to sungate
> > Recv Send Send
> > Socket Socket Message Elapsed
> > Size Size Size Time Throughput
> > bytes bytes bytes secs. 10^6bits/sec
> >
> > 16384 16384 16384 60.01 32.33
> >
> > ^^^
> >
> > The computers are connected with a netgear fs108 switch (full-duplex, 100BTX).
> > The kernel is almost GENERIC.
>
> >
> > Is it a too slow processor problem ? (but it's never used at 100%)
> > Is it a driver/network card problem ?
> > Is it because of pf ? (but there's no changes when I flush all rules)
>
> My worst results are from a P200 with fxp running pf (30Mb/s); disabling
> pf makes it rise to around 45Mb/s; a non-pf freebsd p200 with xl is
> better (60Mb/s), and results seem to improve to around 95Mb/s when P500s
> are used. So it looks as though a slow machine may be a limiting factor,
> at least with this benchmark anyway.
>
> It does appear that pf makes some difference, especially on slower
> machines. The difference is much less significant when there's more CPU
> horsepower. How do your results compare with pfctl -d and pfctl -e?
>
> It may also be worth checking whether your network cards are hard-wired
> to full-duplex or if they are set to autoselect? There maybe a duplex
> mismatch if your switch is set to auto and your nics are hard-wired.
> What does ifconfig -a say? Can you check your switch config?
>
> However, your results seem consistent with mine on a slow machine
> running pf even when the packets are simply passed on that particular
> interface.
>

I did the same test with 'pfctl -d', it's better: 50 * 10^6bits/sec

ifconfig sis0 says:
sis0: flags=8847<UP,BROADCAST,DEBUG,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        address: 00:40:f4:60:76:c5
        media: Ethernet 100baseTX full-duplex
        status: active
        inet6 fe80::240:f4ff:fe60:76c5%sis0 prefixlen 64 scopeid 0x1
        inet 192.168.24.2 netmask 0xffffff00 broadcast 192.168.24.255

I manually specified mediaopt..
And my switch led says the wire is in full-duplex too..

You said you have 95Mb/s with a P500.. under OpenBSD or FreeBSD ?
and with pf enabled ?

I'm thinking .. what kind of computer do we need to fully manage a gigabit
ethernet card ? (they already have direct fiber gigabit internet access
in Japan :)

--
Kabhal