From owner-freebsd-net@FreeBSD.ORG Tue Dec 16 15:36:34 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 86CD116A4CE for ; Tue, 16 Dec 2003 15:36:34 -0800 (PST) Received: from pursued-with.net (adsl-66-125-9-242.dsl.sndg02.pacbell.net [66.125.9.242]) by mx1.FreeBSD.org (Postfix) with ESMTP id BDD0443D35 for ; Tue, 16 Dec 2003 15:36:28 -0800 (PST) (envelope-from Kevin_Stevens@pursued-with.net) Received: from babelfish.pursued-with.net (babelfish.pursued-with.net [192.168.168.42]) by pursued-with.net (Postfix) with ESMTP id 3CF6E67C16; Tue, 16 Dec 2003 15:36:34 -0800 (PST) Date: Tue, 16 Dec 2003 15:36:34 -0800 (PST) From: Kevin Stevens To: Alex In-Reply-To: <5099DCD8-301B-11D8-A624-000A95775140@battleface.com> Message-ID: References: <5099DCD8-301B-11D8-A624-000A95775140@battleface.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: freebsd-net@freebsd.org Subject: Re: suffering from poor network performance... X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Kevin_Stevens@pursued-with.net List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Dec 2003 23:36:34 -0000 On Tue, 16 Dec 2003, Alex wrote: > I have a small home network with a PowerBook G4 and FBSD 4.9-STABLE > connected through a Netgear DS108 hub (10/100). The FBSD box is a dual > Xeon 500MHz with Intel Etherexpress 100/Pro (MS440GX motherboard). If > for some reason it makes a difference, there is an RT311 router > connected to the hub as well. This is the router through which these > machines see the internet. There are other machines connected to the > network. However, they are currently turned off. Ok. > In my limited knowledge I'm using ping from each host to the other. > From the FBSD system to the G4 system, I'm getting nearly 60% packet > loss and about 20% in the other direction. I'm ready to use tcpdump but > I'm not sure how I would. How can/should I go about improving network > performance? tcpdump will only show you packets that ARRIVED - since packet loss is your problem it probably won't help much. > ifconfig on the PowerBook G4 gives: > > en0: flags=8863 mtu 1500 > inet6 fe80::20a:95ff:fe77:5140%en0 prefixlen 64 scopeid 0x4 > inet 192.168.0.3 netmask 0xffffff00 broadcast 192.168.0.255 > ether 00:0a:95:77:51:40 > media: autoselect (100baseTX ) status: active > supported media: none autoselect 10baseT/UTP Ok... > ifconfig on the dual Xeon gives: > > fxp0: flags=8843 mtu 1500 > inet 192.168.0.2 netmask 0xffffff00 broadcast 192.168.0.255 > ether 00:90:27:3e:b2:66 > media: Ethernet autoselect (100baseTX) > status: active > > I know both interfaces are configured for half-duplex. Perhaps How do you know this? The G4 showed half-duplex, the Xeon shows that it is set for autoconfiguration. In any case how they are configured is less important than how they are actually running - not always the same thing. I believe there's a sysctl that can be queried under FreeBSD to provide actual status. Sorry, I'm now exclusively on Mac/OSX, so can't check it for you. > full-duplex would help? How to enable under Mac OS X 10.2? Otherwise, I > know how to do it under FBSD in /etc/rc.conf. You're probably on the right track with a duplex problem. Most hubs default to half-duplex, and it's probably the safest choice to use in any case - most attempts at full-duplexed hubs I've seen have been poor. First, pull the hub out of the middle and connect the G4 to the Xeon with a straight-through Ethernet cable. (All G4 PBs should automatically handle any crossover required). Repeat your ping tests, and observe your duplex config on both machines (should be full duplex). You should see practically no packet loss. Now go back and reconnect each machine to the hub, and verify/confirm half duplex for each device. Repeat tests. If you're still getting packet loss, power cycle the hub. If you're STILL getting packet loss, throw the hub out and buy an 8-port switch for $30, and set the machines to full-duplex. KeS