Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 May 2011 18:49:13 +0200
From:      Laurent Cligny <laurent.cligny@steadinet.fr>
To:        freebsd-xen@freebsd.org
Subject:   Re: [FreeBSD 8.2 amd64 XENHVM] DomU terrible network performance trought NAT
Message-ID:  <4DCC0F89.2060707@steadinet.fr>
In-Reply-To: <BANLkTinMGyeGjvTS5sq=RBb=e=tVC%2BF6OA@mail.gmail.com>
References:  <4DCBEEE0.9060705@steadinet.fr> <BANLkTinMGyeGjvTS5sq=RBb=e=tVC%2BF6OA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------060905080406010700050607
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

Thanks for your quick reply.
> Maybe you should have a look on the tcp window size values.
> I had such a behavior with two gateways who was not playing the same wa=
y
> with the TCP window size which made my network damn slow.
> If you have a linux gateway in front of your FreeBSD VM, it should be t=
his.
Well I compared the TCP default values between the FreeBSD Vm and the
Linux PV VM and changed the net.inet.tcp.recvspace and
net.inet.tcp.sendpace to 124928 wich are the values on the Linux VM, but
there's no change on the network performance. Nice idea, much appreciated=
.
> Command
> Description
> sysctl net.inet.tcp.rfc1323=3D1 Activate window scaling and timestamp o=
ptions
> according to RFC 1323.sysctl ipc.maxsockbuf=3D*[sbmax]* Set maximum siz=
e of
> TCP window.sysctl net.inet.tcp.recvspace=3D*[wstd]* Set default size of=
 TCP
> receive window.sysctl net.inet.tcp.sendspace=3D*[wstd]* Set default siz=
e of
> TCP transmit window.sysctl kern.ipc.nmbclusters View maximum number of =
mbuf
> clusters. Used for storage of data packets to/from the network interfac=
e.
> Can only be set att boot time - see above. sysctl net.inet.tcp.liondmas=
k=3D7Used
> to enable the "netlion" patch above.
>
> Cordialement,
> *Guillaume Seigneuret*
>
>
> *Network and System Security Architect*
>  *Web* :          http://www.omegacube.fr
>  *Address* :
> H=F4tel Technologique Marseille Innovation - BP 100
> 45 rue Frederic Joliot Curie
> Technop=F4le de Ch=E2teau Gombert
> 13382 Marseille Cedex 13
>
>
>
> 2011/5/12 Laurent Cligny <laurent.cligny@steadinet.fr>
>
>> Hello all,
>>
>> I want to setup a FreeBSD DomU VM as a network NAT gateway in order to
>> provide Internet access to other FreeBSD and Linux DomU VMs.
>> My Dom0 is Xen Cloud Platform 1.0 on a Dell Poweredge 210 with 8 cores=
,
>> 16GiB RAM and one NIC.
>>
>> All FreeBSD VM are 8.2 amd64 with XENHVM kernel anf the Linux VM is a
>> Paravirtualized Debian amd64.
>>
>> The NAT gateway is a two-NIC box, with one (xn0) configured with a
>> public Internet address and the other (xn1) configured with a class A
>> private address (10.0.0.254).
>> The Internet traffic is very good from my FreeBSD NAT gateway to the
>> Internet (~ 50MiB/s) and also between other VMs on the private network
>> (~ 70MiB/s trough scp) after applying the patch here
>> (http://www.mail-archive.com/freebsd-xen@freebsd.org/msg00855.html)
>> fixing the "too many frags" problem.
>>
>> Here is a schema of my setup with the observed net speed on it:
>>
>> ----------         ---------------         ----------------------
>> |Internet|---xn0---|FBSD DomU NAT|---xn1---|FBSD and Linux DomUs|
>> ----------         ---------------         ----------------------
>>          <------->               <------->
>>           50MiB/s                 70MiB/s
>>
>>          <------------------------------->
>>           0KiB/s <network speed< 5 KiB/s
>>
>> I tried doing NAT on the FBSD gateway with PF and also with NATd after
>> shutting down PF and unloaded the kernel modules pf.ko and pflog.ko, b=
ut
>> I have the same perf problems with both solutions. Also I tried
>> disabling net.inet.tcp.tso and did ifconfig -tso on all NICs on NAT
>> gateway and other VMs without change.
>>
>> I don't see anything on the error console or in /var/log/message.
>>
>> When i'm trying going though NAT with a Linux paravirt DomU, the netwo=
rk
>> perf is slightly better but don't go over 5KiB/s.
>>
>> Finally I put my Linux paravirt DomU VM as a NAT gateway in place of t=
he
>> FreeBSD one, and the network perf is now normal through it (50MiB/s)
>> from the FreeBSD DomU VMs.
>>
>> As I'm very happy with FreeBSD for my environment I'd like to keep as
>> much as this lovely OS for all my needs, so if anyone have an idea whe=
re
>> the problem can lies, and what to test next to have a clue of what's
>> happening, I will be very thankfull.
>>
>> Thanks in advance.
>>
>> --
>> /Regards,/
>>
>> *Laurent Cligny
>> /Founder/*
>> 02 97 37 71 14
>> 06 25 40 86 48
>> laurent.cligny@steadinet.fr
>>
>> Steadinet <http://www.steadinet.fr>;
>>
>>
>> _______________________________________________
>> freebsd-xen@freebsd.org mailing list
>> http://lists.freebsd.org/mailman/listinfo/freebsd-xen
>> To unsubscribe, send any mail to "freebsd-xen-unsubscribe@freebsd.org"
>>
>>
> _______________________________________________
> freebsd-xen@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-xen
> To unsubscribe, send any mail to "freebsd-xen-unsubscribe@freebsd.org"


--------------060905080406010700050607--





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4DCC0F89.2060707>