Development discussion of WireGuard
 help / color / mirror / Atom feed
* [WireGuard] heavy packet loss
@ 2016-11-04 16:01 k
  2016-11-04 16:04 ` Jason A. Donenfeld
  0 siblings, 1 reply; 3+ messages in thread
From: k @ 2016-11-04 16:01 UTC (permalink / raw)
  To: wireguard

I'm trying to connect 2 endpoints with wireguard.
One endpoint has MTU of inet inteface 1500, another 1456.
To prevent packet fragmentation on inet interface i set up mtu 1383 for both wg interfaces. Checked that no frag occurs on inet interface in wireshark. Maximum packet data size is 1383-28 = 1355. Checked with no-fragment ping, packets pass well.

First I checked packet loss between inet IPs

iperf  -c x.x.x.x -u -b 25M -l 1400
0.0-10.3 sec  29.6 MBytes  24.2 Mbits/sec  16.073 ms  175/23090 (0.76%)

packet loss always within 0.5..1%. its normal
now I try to do the same with much less bandwidth between wireguard ips
on packet size <=1252 packet loss rate is 0.5..1%

iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1252
0.0-10.0 sec  1.18 MBytes   991 Kbits/sec   0.659 ms    9/ 1000 (0.9%)

but starting from packet size 1253 packets loss greatly increases. its 6..10%

iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1253
0.0-10.0 sec  1.12 MBytes   936 Kbits/sec   0.328 ms   64/  998 (6.4%)

Thats why TCP is incredibly slow. If I set up mss for TCP to not exceed packets size threshold TCP is fast.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [WireGuard] heavy packet loss
  2016-11-04 16:01 [WireGuard] heavy packet loss k
@ 2016-11-04 16:04 ` Jason A. Donenfeld
  2016-11-04 16:18   ` k
  0 siblings, 1 reply; 3+ messages in thread
From: Jason A. Donenfeld @ 2016-11-04 16:04 UTC (permalink / raw)
  To: k; +Cc: WireGuard mailing list

Hi k,

I'll look into this. Which snapshot are you using? Or, which commit is this?

Jason


On Fri, Nov 4, 2016 at 5:01 PM,  <k@vodka.home.kg> wrote:
> I'm trying to connect 2 endpoints with wireguard.
> One endpoint has MTU of inet inteface 1500, another 1456.
> To prevent packet fragmentation on inet interface i set up mtu 1383 for both wg interfaces. Checked that no frag occurs on inet interface in wireshark. Maximum packet data size is 1383-28 = 1355. Checked with no-fragment ping, packets pass well.
>
> First I checked packet loss between inet IPs
>
> iperf  -c x.x.x.x -u -b 25M -l 1400
> 0.0-10.3 sec  29.6 MBytes  24.2 Mbits/sec  16.073 ms  175/23090 (0.76%)
>
> packet loss always within 0.5..1%. its normal
> now I try to do the same with much less bandwidth between wireguard ips
> on packet size <=1252 packet loss rate is 0.5..1%
>
> iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1252
> 0.0-10.0 sec  1.18 MBytes   991 Kbits/sec   0.659 ms    9/ 1000 (0.9%)
>
> but starting from packet size 1253 packets loss greatly increases. its 6..10%
>
> iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1253
> 0.0-10.0 sec  1.12 MBytes   936 Kbits/sec   0.328 ms   64/  998 (6.4%)
>
> Thats why TCP is incredibly slow. If I set up mss for TCP to not exceed packets size threshold TCP is fast.
>
> _______________________________________________
> WireGuard mailing list
> WireGuard@lists.zx2c4.com
> http://lists.zx2c4.com/mailman/listinfo/wireguard

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [WireGuard] heavy packet loss
  2016-11-04 16:04 ` Jason A. Donenfeld
@ 2016-11-04 16:18   ` k
  0 siblings, 0 replies; 3+ messages in thread
From: k @ 2016-11-04 16:18 UTC (permalink / raw)
  To: Jason A. Donenfeld; +Cc: WireGuard mailing list

Problematic version was 0.0.20161025.
I upgraded kmod to 0.0.20161103 at it works fine now.

> Hi k,

> I'll look into this. Which snapshot are you using? Or, which commit is th=
is?

> Jason


> On Fri, Nov 4, 2016 at 5:01 PM,  <k@vodka.home.kg> wrote:
>> I'm trying to connect 2 endpoints with wireguard.
>> One endpoint has MTU of inet inteface 1500, another 1456.
>> To prevent packet fragmentation on inet interface i set up mtu 1383 for =
both wg interfaces. Checked that no frag occurs on inet interface in wiresh=
ark. Maximum packet data size is 1383-28 =3D 1355. Checked with no-fragment=
 ping, packets pass well.
>>
>> First I checked packet loss between inet IPs
>>
>> iperf  -c x.x.x.x -u -b 25M -l 1400
>> 0.0-10.3 sec  29.6 MBytes  24.2 Mbits/sec  16.073 ms  175/23090 (0.76%)
>>
>> packet loss always within 0.5..1%. its normal
>> now I try to do the same with much less bandwidth between wireguard ips
>> on packet size <=3D1252 packet loss rate is 0.5..1%
>>
>> iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1252
>> 0.0-10.0 sec  1.18 MBytes   991 Kbits/sec   0.659 ms    9/ 1000 (0.9%)
>>
>> but starting from packet size 1253 packets loss greatly increases. its 6=
..10%
>>
>> iperf  -c 192.168.254.65 -w 500000 -u -b 1M -l 1253
>> 0.0-10.0 sec  1.12 MBytes   936 Kbits/sec   0.328 ms   64/  998 (6.4%)
>>
>> Thats why TCP is incredibly slow. If I set up mss for TCP to not exceed =
packets size threshold TCP is fast.
>>
>> _______________________________________________
>> WireGuard mailing list
>> WireGuard@lists.zx2c4.com
>> http://lists.zx2c4.com/mailman/listinfo/wireguard

--=20
=D0=A1 =D1=83=D0=B2=D0=B0=D0=B6=D0=B5=D0=BD=D0=B8=D0=B5=D0=BC,
 K                          mailto:k@vodka.home.kg

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-11-04 16:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-04 16:01 [WireGuard] heavy packet loss k
2016-11-04 16:04 ` Jason A. Donenfeld
2016-11-04 16:18   ` k

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).