From owner-freebsd-performance@FreeBSD.ORG Thu Nov 23 16:52:31 2006 Return-Path: X-Original-To: freebsd-performance@freebsd.org Delivered-To: freebsd-performance@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 73F1116A412 for ; Thu, 23 Nov 2006 16:52:31 +0000 (UTC) (envelope-from mike@sentex.net) Received: from smarthost2.sentex.ca (smarthost2.sentex.ca [205.211.164.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 49B9C43D8C for ; Thu, 23 Nov 2006 16:51:44 +0000 (GMT) (envelope-from mike@sentex.net) Received: from lava.sentex.ca (pyroxene.sentex.ca [199.212.134.18]) by smarthost2.sentex.ca (8.13.8/8.13.8) with ESMTP id kANGqKDK010758; Thu, 23 Nov 2006 11:52:20 -0500 (EST) (envelope-from mike@sentex.net) Received: from mdt-xp.sentex.net (simeon.sentex.ca [192.168.43.27]) by lava.sentex.ca (8.13.6/8.13.3) with ESMTP id kANGqJsr005016 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 23 Nov 2006 11:52:19 -0500 (EST) (envelope-from mike@sentex.net) Message-Id: <200611231652.kANGqJsr005016@lava.sentex.ca> X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Date: Thu, 23 Nov 2006 11:52:22 -0500 To: Jeremie Le Hen From: Mike Tancsa In-Reply-To: <20061122130947.GM20405@obiwan.tataz.chchile.org> References: <4557CECD.2000609@samsco.org> <200611130158.kAD1wdKE040908@lava.sentex.ca> <4557EF13.9060305@samsco.org> <200611130454.kAD4sZwe041556@lava.sentex.ca> <4557FF7A.8020704@samsco.org> <200611132054.kADKsFvK045726@lava.sentex.ca> <4558E3DC.6080800@samsco.org> <200611200454.kAK4sdat083568@lava.sentex.ca> <7.1.0.9.0.20061120160757.14d4a728@sentex.net> <200611220247.kAM2l9JP095066@lava.sentex.ca> <20061122130947.GM20405@obiwan.tataz.chchile.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Cc: freebsd-performance@freebsd.org Subject: Re: em forwarding performance (was Proposed 6.2 em RELEASE patch X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Nov 2006 16:52:31 -0000 At 08:09 AM 11/22/2006, Jeremie Le Hen wrote: >It would be interesting to know the real performance of Linux as a mere >router if we want a true comparision with FreeBSD performances. Re-tested, this time with a LINUX UP kernel and there is not that much difference in overall speeds. I added a few IPTABLES rules which loaded a few of the modules. [root@r2 ~]# iptables -A OUTPUT -p tcp -s 10.90.2.1 --dport 135:139 -j DROP [root@r2 ~]# iptables -A OUTPUT -p tcp -s 11.90.3.1 --dport 445 -j DROP [root@r2 ~]# iptables -A OUTPUT -p tcp -s 0.0.0.0/0 --dport 448 -j REJECT [root@r2 ~]# [root@r2 ~]# lsmod Module Size Used by ipt_REJECT 5248 1 xt_tcpudp 3456 3 iptable_filter 3328 1 ip_tables 12872 1 iptable_filter x_tables 14212 3 ipt_REJECT,xt_tcpudp,ip_tables autofs4 21508 2 sunrpc 153660 1 acpi_cpufreq 8204 0 dm_mirror 21968 0 dm_multipath 18568 0 dm_mod 57112 2 dm_mirror,dm_multipath video 17028 0 sbs 16192 0 i2c_ec 5376 1 sbs button 7184 0 battery 10500 0 asus_acpi 16792 0 ac 5636 0 pcspkr 3456 0 i2c_nforce2 7552 0 i2c_core 21504 2 i2c_ec,i2c_nforce2 serio_raw 7300 0 tg3 99972 0 e1000 114752 0 ide_cd 38432 0 cdrom 34848 1 ide_cd forcedeth 39940 0 sata_nv 11652 0 libata 98068 1 sata_nv sd_mod 20864 0 scsi_mod 133672 2 libata,sd_mod ext3 129416 1 jbd 58152 1 ext3 ehci_hcd 30984 0 ohci_hcd 19844 0 uhci_hcd 23052 0 [root@r2 ~]# Stopping it does seem to unload the klds [root@r2 ~]# /etc/rc.d/init.d/iptables stop Flushing firewall rules: [ OK ] Setting chains to policy ACCEPT: filter [ OK ] Unloading iptables modules: [ OK ] [root@r2 ~]# [root@r2 ~]# lsmod Module Size Used by ipt_REJECT 5248 0 xt_tcpudp 3456 0 x_tables 14212 2 ipt_REJECT,xt_tcpudp autofs4 21508 2 sunrpc 153660 1 acpi_cpufreq 8204 0 dm_mirror 21968 0 dm_multipath 18568 0 dm_mod 57112 2 dm_mirror,dm_multipath video 17028 0 sbs 16192 0 i2c_ec 5376 1 sbs button 7184 0 battery 10500 0 asus_acpi 16792 0 ac 5636 0 pcspkr 3456 0 i2c_nforce2 7552 0 i2c_core 21504 2 i2c_ec,i2c_nforce2 serio_raw 7300 0 tg3 99972 0 e1000 114752 0 ide_cd 38432 0 cdrom 34848 1 ide_cd forcedeth 39940 0 sata_nv 11652 0 libata 98068 1 sata_nv sd_mod 20864 0 scsi_mod 133672 2 libata,sd_mod ext3 129416 1 jbd 58152 1 ext3 ehci_hcd 30984 0 ohci_hcd 19844 0 uhci_hcd 23052 0 [root@r2 ~]# RELENG_4 still seems to be king, speed wise for raw forwarding and firewalling performance. I tried Dragon Fly, but the em NICs lock up with a few packets blasted at it both in SMP and UP mode. Also tried booting one of their development kernels, but no difference. I might give OpenBSD a quick try as a reference. I also tried a few variations in the kernel from CURRENT. Removing things like KTRACE and PREMPTION seem to have very little impact, but some. Also tried changing the hardware timer to TSC, but that didnt have any impact.