From owner-freebsd-performance@FreeBSD.ORG Wed Sep 29 21:09:47 2010 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 05E111065693 for ; Wed, 29 Sep 2010 21:09:47 +0000 (UTC) (envelope-from faust64@gmail.com) Received: from mail-qy0-f182.google.com (mail-qy0-f182.google.com [209.85.216.182]) by mx1.freebsd.org (Postfix) with ESMTP id A45CE8FC16 for ; Wed, 29 Sep 2010 21:09:46 +0000 (UTC) Received: by qyk7 with SMTP id 7so1863142qyk.13 for ; Wed, 29 Sep 2010 14:09:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:from:date :message-id:subject:to:content-type; bh=wfbDSeg3hVLuyl42WOnwpxRUx9c+wvP1s7PlQJbTUKM=; b=fEvFVx2B4aaiiToRq9htgJzkosFfXXDfFAFkyvjn5Notu5tUPomhQZI6U4g3i6M+hX 4JaaaEwRY74n+PK1Op+Gi1YK3QxSpevfq4Qda8dTKzfrNPEKmQPA38nc5aQICU2DigQe ogaDsO2NUmHSb5ZXFterEg203S+Nk/DSFhUu8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:content-type; b=uV4gNtqK24wrrx6zAQGzU78UYcdOIqVnbm6LChOcSMXxd6Ym0wtzdAiKRkngAY+M1R wcYu2asnjKaNQkgkCrx9uvpX7gEjjwGLbykX4oGCy4uJMFAD93OTpZnQ3Q7Vwsp12X7i UL+3pk8F8sekY3OuvvQfpmg21FBg0P0By7wts= Received: by 10.229.52.38 with SMTP id f38mr1363055qcg.224.1285793137543; Wed, 29 Sep 2010 13:45:37 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.10.103 with HTTP; Wed, 29 Sep 2010 13:44:53 -0700 (PDT) From: =?ISO-8859-1?Q?Samuel_Mart=EDn_Moro?= Date: Wed, 29 Sep 2010 22:44:53 +0200 Message-ID: To: freebsd-performance@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: freebsd router 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: Wed, 29 Sep 2010 21:09:47 -0000 Hi, I'm trying to replace my (dying) gateway with a qnap ts-509 (1G DDR, celero= n m420 1.6Ghzs). I'm using mfsBSD, based on FreeBSD-RELEASE-8.1 amd64. It's almost ready (zfs, nfs, dns, pf, ...), I'm checking everything's OK to swap the gate. I noticed that opening a new connection to distant or local computer is (very) slow. After that, everything works perfectly fine. So I had a look at sysctl, and tried to fix that problem. Now, when I start a ping on a client from my network (disabled on the gate)= , I have something like that: faust@alpha ~ : time ping -c 4 google.com PING google.com (66.249.92.104) 56(84) bytes of data. 64 bytes from par03s01-in-f104.1e100.net (66.249.92.104): icmp_seq=3D1 ttl= =3D53 time=3D7.12 ms 64 bytes from par03s01-in-f104.1e100.net (66.249.92.104): icmp_seq=3D2 ttl= =3D53 time=3D7.32 ms 64 bytes from par03s01-in-f104.1e100.net (66.249.92.104): icmp_seq=3D3 ttl= =3D53 time=3D7.18 ms 64 bytes from par03s01-in-f104.1e100.net (66.249.92.104): icmp_seq=3D4 ttl= =3D53 time=3D7.18 ms --- google.com ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 15034ms rtt min/avg/max/mdev =3D 7.126/7.205/7.329/0.128 ms 0.000u 0.000s 0:25.08 0.0% 0+0k 0+0io 0pf+0w So, it takes 5 seconds to display the first line (connect), and then 5 second per ping. 25 seconds, for 4 pings... Obviously, my tries doesn't make it work any better... I found some infos here , here , there and there But I'm still not sure about the tuning implications for most of those vars= . Here is my sysctl.conf: kern.coredump=3D0 kern.ipc.somaxconn=3D4096 net.inet.ip.check_interface=3D1 net.inet.ip.fastforwarding=3D1 net.inet.ip.forwarding=3D1 net.inet.ip.portrange.first=3D1024 net.inet.ip.portrange.last=3D65535 net.inet.ip.rtexpire=3D2 net.inet.ip.rtmaxcache=3D256 net.inet.ip.rtminexpire=3D2 net.inet.ip.ttl=3D42 net.inet.udp.blackhole=3D1 net.inet.tcp.blackhole=3D2 net.inet.tcp.delacktime=3D42 net.inet.tcp.delayed_ack=3D0 net.inet.tcp.drop_synfin=3D1 net.inet.tcp.fast_finwait2_recycle=3D1 net.inet.tcp.icmp_may_rst=3D0 net.inet.icmp.icmplim=3D42 net.inet.tcp.ecn.enable=3D1 net.inet.tcp.msl=3D5000 net.inet.tcp.rfc1323=3D0 net.inet.tcp.inflight.enable=3D1 net.inet.tcp.inflight.max=3D1073725440 net.inet.tcp.inflight.stab=3D20 net.inet.tcp.inflight.min=3D1024 net.inet.tcp.recvspace=3D82320 net.inet.tcp.sendspace=3D82320 net.inet.udp.maxdgram=3D82320 net.inet.udp.recvspace=3D82320 net.inet.raw.maxdgram=3D82320 net.inet.raw.recvspace=3D82320 net.local.dgram.maxdgram=3D82320 net.local.dgram.recvspace=3D82320 net.local.stream.sendspace=3D82320 net.local.stream.recvspace=3D82320 net.inet.tcp.local_slowstart_flightsize=3D10 net.inet.tcp.nolocaltimewait=3D1 vfs.read_max=3D32 So, I was wondering, is something wrong in there? Or should I keep looking somewhere else? Where? Thanks for your help, --=20 Samuel Mart=EDn Moro {EPITECH.} tek5