Re: slow network performance in bhyve with freebsd guests compared with any other guest os

From: void <void_at_f-m.fm>
Date: Sun, 29 Sep 2024 12:46:57 UTC
On Sun, Sep 29, 2024 at 08:12:23AM +0100, Lexi Winter wrote:
>On 29/09/2024 07:58, void wrote:
>>Surprisingly, freebsd guest performance is about 1/3rd of the line speed.
>>Do some sysctls need to be tuned in freebsd specifically for when it 
>>is in a guest context?
>
>i tested this here and cannot reproduce the problem:

The iperf3 performance is appears to be heavily influenced by load.
The linux guest still massively outperforms the freebsd guests

The tests I posted before were when the bhyve host wasn't under much load. 0.00
to 1.00.

Right now, load is like
uptime
  1:38p.m.  up  4:14, 2 users, load averages: 33.66, 33.47, 33.55

  and iperf3 performance for freebsd 14-p5 guest is

  [ ID] Interval           Transfer     Bitrate         Retr
  [  5]   0.00-30.25  sec   143 MBytes  39.8 Mbits/sec    5             sender
  [  5]   0.00-30.25  sec   143 MBytes  39.8 Mbits/sec                  receiver

  and performance for ubuntu guest is

  [ ID] Interval           Transfer     Bitrate         Retr
  [  5]   0.00-30.04  sec   778 MBytes   217 Mbits/sec   78             sender
  [  5]   0.00-30.11  sec   776 MBytes   216 Mbits/sec                  receiver

I think it might be due to mabe interrupts, epoll (which i think is a linux
thing), maybe queueing. But I dont know how to fix it.

Testing from the bhyve host (so no bhyve involvement) is line speed regardless
of load. Maybe it's the way bhyve handles interrupts?
--