Date: Sun, 7 Nov 2010 15:10:20 -0800 From: Pyun YongHyeon <pyunyh@gmail.com> To: stable@freebsd.org Subject: Re: Abysmal re(4) performance under 8.1-STABLE (mid-August) Message-ID: <20101107231020.GB1279@michelle.cdnetworks.com> In-Reply-To: <20101107112421.GH85693@acme.spoerlein.net> References: <20101106093700.GW85693@acme.spoerlein.net> <AANLkTinqcv0M_CR9uHWtjOeHNHt4QGjhS_wNNOjJinu_@mail.gmail.com> <20101107112421.GH85693@acme.spoerlein.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Nov 07, 2010 at 12:24:21PM +0100, Ulrich Sp??rlein wrote: > On Sat, 06.11.2010 at 23:19:33 -0700, Pyun YongHyeon wrote: > > On Sat, Nov 6, 2010 at 2:37 AM, Ulrich Sp??rlein <uqs@spoerlein.net> wrote: > > > Hello Pyun, > > > > > > On this new server, I cannot get more than ~280kByte/s up/downstream out of > > > re(4) without any tweaking. > > > > > > re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 > > > ?? ?? ?? ??options=389b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_UCAST,WOL_MCAST,WOL_MAGIC> > > > ?? ?? ?? ??ether 00:21:85:63:74:34 > > > ?? ?? ?? ??inet6 fe80::221:85ff:fe63:7434%re0 prefixlen 64 scopeid 0x1 > > > ?? ?? ?? ??inet 46.4.12.147 netmask 0xffffffc0 broadcast 46.4.12.191 > > > ?? ?? ?? ??nd6 options=3<PERFORMNUD,ACCEPT_RTADV> > > > ?? ?? ?? ??media: Ethernet autoselect (100baseTX <half-duplex>) > > > ?? ?? ?? ??status: active > > > > > > > It seems the link was resolved to half-duplex. Does link partner > > also agree on the resolved speed/duplex? > > As this is a dedicated server in a colo hundreds of km away, I have no > means to check this easily. Especially I cannot change the setting from > auto-neg. Btw, linux will show a negotiated 100/full link via mii-tool. > I guess you can contact network administrator of the data center to check the switch configuration. IEEE 802.3 says if link parter use forced full-duplex media and you use auto media, the resolved duplex is half-duplex by definition. I think RealTek may have followed the standard. There is no reason to use manual media configuration unless your link partner is severely broken with auto-negotiation. Due to silicon bug of RealTek PHYs, rgephy(4) always use auto-negotiation so manual media configuration is a kind of auto-negotiation with limited set of available media advertising. I don't know how Linux solve the silicon bug though. One of magic DSP fixups might fix the issue, the DSP fixups vendor released is not under BSD license and does not say more detailed information for the code. > > > # ifconfig re0 > > > re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 > > > ?? ?? ?? ??options=88<VLAN_MTU,VLAN_HWCSUM> > > > ?? ?? ?? ??ether 00:21:85:63:74:34 > > > ?? ?? ?? ??inet6 fe80::221:85ff:fe63:7434%re0 prefixlen 64 scopeid 0x1 > > > ?? ?? ?? ??inet 46.4.12.147 netmask 0xffffffc0 broadcast 46.4.12.191 > > > ?? ?? ?? ??nd6 options=3<PERFORMNUD,ACCEPT_RTADV> > > > ?? ?? ?? ??media: Ethernet 100baseTX <full-duplex> (100baseTX <half-duplex>) > > > ?? ?? ?? ??status: active > > > > > > > This time, it seems you used forced media configuration > > instead of auto. It still shows duplex mismatch so it's > > normal to see poor performance. What makes me wonder > > is why you have duplex mismatch? > > Did you use forced media configuration on link partner? > > What happens when you use different switch? > > Sadly, none of these options are available to me :/ > But even 100/half should give more than enough performance, right? > No, with half-duplex link, you can't send frames while RX is in progress. The reverse is also true for half-duplex link. The more severe problem is your link partner think it established full-duplex link so it does not care about possible collisions. Either change your link partner's media configuration to half-duplex or auto. auto is preferred one, of course.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20101107231020.GB1279>