Re: vr speed issues



On Tue, Nov 28, 2006 at 10:50:17PM -0500, Charles Sprickman wrote:
Hi all,

I spent some time trying to track down slow tcp performance on a small
office switched 100 LAN. We just put in a number of whitebox PCs running
FreeBSD 6.1-p2/PC-BSD 1.2 that all have onboard Via Rhine 10/100 ethernet
controllers. Performace with scp was around 200KB/s, ftp wavered between
300-500KB/s. This did not appear to be a duplex mismatch - unmanaged
switch showed them all at 100/Full, put some other hosts on the same
ports/cabling and got near wire speed. I took the cabling out of the
equation, the switch, no improvement. The only thing that got me decent
performance was putting two hosts back to back with an xover cable.

I eventually realized that the only hosts with any speed issues in the
office were these boxes with the Via ethernet. Putting an equally cheap
DLink (RealTek/rl) in one of them gave me much better performance.

At another site, I was dealing with a new intranet server running FreeBSD
6.2-PRE (11/16) on a decent Asus board. This also has an onboard Via
Rhine ethernet controller. While pulling some files over from the box it
was replacing, I noticed that I was getting only a few hundred KB/s on
this box. Before putting it into production, I grabbed a cheap Intel
10/100 card and put that in. Problem solved.

So it seems to me like perhaps there's an issue with the vr driver. I
noticed it does have some quirks mentioned in the manpage, and I don't see
too many changes to the driver in the last year or so.

Is there any information I can supply to help debug this? I've got a
bunch of these machines around. I can get a tcpdump from both ends during
an ftp transfer, and the boxes are mine to toy with after hours.

I've posted a dmesg from both boxes (PC-BSD and 6.2-PRE):

http://www.bway.net/~spork/6.1p2-dmesg.txt
http://www.bway.net/~spork/6.2-dmesg.txt


VIA Rhine has severe hardware limitations and you can't expect good
performance from the NIC. On Tx side the NIC need 4 bytes aligned mbuf
so the driver defragments the mbuf chains with m_defrag(9).
On Rx side it strips off CRC with m_devget(9) as the NIC has no way
to remove the CRC from the received frame. These m_defrag(9)/
m_devget(9) results in bcopy operation and they nullyfies the
advantage of DMA which in trun waste significant CPU cycles.

If you are in bad need of getting full 100Mbps speed you could buy
a cheap PCI gigabit NIC that is supported by re(4)/sk(4)/stge(4)
etc.

--
Regards,
Pyun YongHyeon
_______________________________________________
freebsd-stable@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • [git patches] IDE updates (part 4)
    ... ide: add IDE_HFLAG_BOOTABLE host flag ... alim15x3: always tune PIO ... Fix siimage driver accessing beyond array boundary ... There is a 25/33MHz switch in configuration ...
    (Linux-Kernel)
  • Re: [PATCH] atmel_serial: update the powersave handler to match serial core
    ... I think that a driver can do the request to a the gpio layer (may can be implemented ... pin change interrupt. ... For waking up, we need to switch on the main oscillator, wait until it ...
    (Linux-Kernel)
  • Re: [PATCH][RESEND] New type of DTV2000H TV Card
    ... But I had installed GPG and signed my patch, maybe this is what I should have done earlier. ... This piece of code used to switch the input of RF signal to "Air Antenna" ... if this patch (and driver) would be able to switch RF ... inputs in DVB-T mode somehow. ...
    (Linux-Kernel)
  • RE: Wirless LAN
    ... Install one of the several GOOD "wireless switch" back-end boxes, ... Require some kind of login to access out of the VLAN. ... switch" products just use the user login to group clients into VLANs, ...
    (Security-Basics)
  • Re: Polo..
    ... Brake light switch failure is a very common problem with all ... never the solid German engineering. ... so WTF use a cheap switch on my expensive piece of German ... "Screw the fact the Ford is more reliable, cheaper to fix, cheaper to run, ...
    (uk.rec.cars.misc)