From nobody Wed Oct 22 18:27:33 2025 X-Original-To: freebsd-net@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4csHj15LfWz6D4mp for ; Wed, 22 Oct 2025 18:28:05 +0000 (UTC) (envelope-from ccfreebsd@gmail.com) Received: from mail-yw1-f180.google.com (mail-yw1-f180.google.com [209.85.128.180]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "WR4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4csHj13kZRz427C for ; Wed, 22 Oct 2025 18:28:05 +0000 (UTC) (envelope-from ccfreebsd@gmail.com) Authentication-Results: mx1.freebsd.org; none Received: by mail-yw1-f180.google.com with SMTP id 00721157ae682-7836ef02ef1so6178477b3.3 for ; Wed, 22 Oct 2025 11:28:05 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1761157684; x=1761762484; h=references:to:cc:in-reply-to:date:subject:mime-version:message-id :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=NJYTCnzdkKXI59oEml4qzPtxT0J74MCKNWxvziHhIyw=; b=qoAJRJQh6P3+WzizAIuPLa11HlHvv9x6YX/CUp21Nyh0jM/O//qdLkyGNv5G8dw1Uq M6bXQ/Y+XeYEBzhFSY15vY0rL/QALvN864/OSPDmAVlEdmRGN5G4xNf0gaYEK4OnmCI6 i0WgekiBT7J82GyHVlVLNoyJdR94trPoV7TqkuDzNjSV1w144XCkivg/nWFRIob3WDWz 07tyQqiwTB7F/kO5Rnx2cwMRpDBfjjGVodJGXKtDKvFZMIhVdIm8i84i/Ry925eBOsEu lOJG7RTWM9MuqVli37jXd165EvIuDcnHVyvAFOgWoxCBEdLPb3f+DFMBhIJYBLiDqZfU HOKQ== X-Gm-Message-State: AOJu0Yw9ewq0L7aMedpRnOzvljEztQ9VVJz1rTLXK2HX450zm4zxRWka XR12E6yyQ21KdYNJ5+p5zIogbfazb3ZlzVQpC7y6cN9QQ3+wll85tWFU2nrDeg== X-Gm-Gg: ASbGnctI/O0lBsdMmf9TxL3Gs3Sk1HJ/TMCEMJtg30dJh3Lp0+8L9FJxuNmeXMS/a/E LA81fIqdL/1ViKGQY/PvMO0PyBHjcqgdm+eb1fGlFKJVpCOVyoVcl8W0TyyPi6vtWY6r6o2ZpNV Kxk+W0CKlbrXotookYIU8VmU3L+xiWQ3PI2xyNv4d+XJUR9aRIqq/miwX6LOFgORcBuD19TZN8L TLBb4lngyFn4f3fZYi1tp0oBK2gAuKP02tkQdgHf1Bt+VRR0j+QNPxaUreY5fWs+wp0EIa0obbx xovLGGmUpXUJnoGy+07/SELK+zFrl4Qv5Fugw6QNtsA3PZtAahh6Xt8+Dv+rDghMp2VREHPRMap oApWda4JpPzqVGLLc3lEjBwJAAycoTRGES/T/IGm0NVttNBPlCtARdlJAOcKOf1Z2eN9q9+YIgh FkCU1YkKGDDVTDTKmjNkIZECCJ3KuCe1tNwFA= X-Google-Smtp-Source: AGHT+IEVt9Ke3r8aJvApsxGzuVUosIi+deLwPTV3DjnP9/ws5DF2sqswQj2VmDEalB4wI/YB4NokeA== X-Received: by 2002:a05:690e:1284:b0:63e:38c9:6fa2 with SMTP id 956f58d0204a3-63ea1bae28emr4049138d50.9.1761157684306; Wed, 22 Oct 2025 11:28:04 -0700 (PDT) Received: from smtpclient.apple ([2600:1700:841:34f0:4515:226e:7d10:6efe]) by smtp.gmail.com with ESMTPSA id 956f58d0204a3-63e267fe371sm4207832d50.19.2025.10.22.11.28.03 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 22 Oct 2025 11:28:03 -0700 (PDT) From: Cheng Cui Message-Id: <51300B68-3D16-434E-8A65-696EC48FA98C@freebsd.org> Content-Type: multipart/alternative; boundary="Apple-Mail=_77D438CE-EAF7-4AAD-AD97-D7A69CC54874" List-Id: Networking and TCP/IP with FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-net List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-net@FreeBSD.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.100.1.1.5\)) Subject: Re: vtnet is still slow Date: Wed, 22 Oct 2025 14:27:33 -0400 In-Reply-To: Cc: freebsd-net@freebsd.org To: void References: X-Mailer: Apple Mail (2.3864.100.1.1.5) X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US] X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Rspamd-Queue-Id: 4csHj13kZRz427C --Apple-Mail=_77D438CE-EAF7-4AAD-AD97-D7A69CC54874 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Interesting, my Bhyve host node "n1" and my MacbookProM1 laptop are = wired to the same 1Gbps home switch. The "n1" runs FreeBSD stable/14-9e40b536cb58 and Bhyve, with ethernet = port re0. The "n1fbsd15x" VM runing FreeBSD stable/15-01a653205313 is a = guest in "n1" with vtnet0 port. All sysctl values in default. The iperf3 "iperf3 -c laptop -i1 -t10" traffic sent from the "n1fbsd15x" = VM to my laptop: [ ID] Interval Transfer Bitrate Retr Cwnd [ 5] 0.00-1.08 sec 89.5 MBytes 695 Mbits/sec 37 501 KBytes = =20 [ 5] 1.08-2.08 sec 112 MBytes 946 Mbits/sec 0 759 KBytes = =20 [ 5] 2.08-3.08 sec 113 MBytes 946 Mbits/sec 0 949 KBytes = =20 [ 5] 3.08-4.07 sec 111 MBytes 943 Mbits/sec 6 5.66 KBytes = =20 [ 5] 4.07-5.07 sec 112 MBytes 941 Mbits/sec 0 705 KBytes = =20 [ 5] 5.07-6.01 sec 106 MBytes 941 Mbits/sec 0 817 KBytes = =20 [ 5] 6.01-7.07 sec 119 MBytes 942 Mbits/sec 0 915 KBytes = =20 [ 5] 7.07-8.07 sec 112 MBytes 942 Mbits/sec 0 984 KBytes = =20 [ 5] 8.07-9.07 sec 112 MBytes 942 Mbits/sec 0 1.01 MBytes = =20 [ 5] 9.07-10.07 sec 113 MBytes 941 Mbits/sec 0 1.04 MBytes = =20 - - - - - - - - - - - - - - - - - - - - - - - - - [ ID] Interval Transfer Bitrate Retr [ 5] 0.00-10.07 sec 1.07 GBytes 916 Mbits/sec 43 = sender [ 5] 0.00-10.08 sec 1.07 GBytes 914 Mbits/sec = receiver iperf Done. My Bhyve setup: = https://wiki.freebsd.org/chengcui/install_FreeBSD13_VM_via_bhyve > On Oct 22, 2025, at 10:03, void wrote: >=20 > Hi, >=20 > I wondered if any work was happening to address the long-standing = issue > of slow vtnet? (in my case, this leads to slow freebsd guest = performance > in bhyve compared with every linux guest tested and OpenBSD). >=20 > I thought maybe the recent bridge work may have ameliorated the = problem some, but testing, after configuring a (recent) stable/15 server = to use the ip-configured-on-bridge-method, showed no improvement using > a (recent) stable/14 guest >=20 > [ ID] Interval Transfer Bitrate Retr > [ 5] 0.00-60.03 sec 3.17 GBytes 454 Mbits/sec 0 sender > [ 5] 0.00-60.03 sec 3.17 GBytes 454 Mbits/sec receiver >=20 > for comparison, an ubuntu 25.04 guest: >=20 > [ ID] Interval Transfer Bitrate Retr > [ 5] 0.00-60.00 sec 6.42 GBytes 919 Mbits/sec 5427 sender > [ 5] 0.00-60.00 sec 6.42 GBytes 919 Mbits/sec receiver >=20 > the baremetal host >=20 > [ ID] Interval Transfer Bitrate Retr > [ 5] 0.00-60.01 sec 6.58 GBytes 941 Mbits/sec 0 sender > [ 5] 0.00-60.01 sec 6.58 GBytes 941 Mbits/sec receiver >=20 > Tests done a year and a half ago on similar hardware showing > the same patterns http://void.f-m.fm.user.fm/bhyve-virtio-testing.html > --=20 >=20 Best Regards, Cheng Cui --Apple-Mail=_77D438CE-EAF7-4AAD-AD97-D7A69CC54874 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii Interesting, my Bhyve host node "n1" and = my MacbookProM1 laptop are wired to the same 1Gbps home = switch.

The "n1" runs FreeBSD stable/14-9e40b536cb58 and Bhyve, with ethernet = port re0. The = "n1fbsd15x" VM runing FreeBSD stable/15-01a653205313 is a guest in "n1" = with vtnet0 port. All sysctl values in = default.

The iperf3 "iperf3 -c laptop -i1 = -t10" traffic sent from the "n1fbsd15x" VM to my laptop:

[ ID] Interval =           Transfer     Bitrate   =       Retr  Cwnd

[  5]   = 0.00-1.08   sec  89.5 MBytes   695 Mbits/sec   = 37    501 KBytes       

[  5]   = 1.08-2.08   sec   112 MBytes   946 Mbits/sec    = 0    759 KBytes       

[  5]   = 2.08-3.08   sec   113 MBytes   946 Mbits/sec    = 0    949 KBytes       

[  5]   = 3.08-4.07   sec   111 MBytes   943 Mbits/sec    = 6   5.66 KBytes       

[  5]   = 4.07-5.07   sec   112 MBytes   941 Mbits/sec    = 0    705 KBytes       

[  5]   = 5.07-6.01   sec   106 MBytes   941 Mbits/sec    = 0    817 KBytes       

[  5]   = 6.01-7.07   sec   119 MBytes   942 Mbits/sec    = 0    915 KBytes       

[  5]   = 7.07-8.07   sec   112 MBytes   942 Mbits/sec    = 0    984 KBytes       

[  5]   = 8.07-9.07   sec   112 MBytes   942 Mbits/sec    = 0   1.01 MBytes       

[  5]   = 9.07-10.07  sec   113 MBytes   941 Mbits/sec    = 0   1.04 MBytes       

- - - - - - - - - = - - - - - - - - - - - - - - - -

[ ID] Interval =           Transfer     Bitrate   =       Retr

[  5]   = 0.00-10.07  sec  1.07 GBytes   916 Mbits/sec   = 43            sender

[  5]   = 0.00-10.08  sec  1.07 GBytes   914 Mbits/sec    =               receiver


iperf = Done.


My Bhyve = setup: https://wiki.freebsd.org/chengcui/install_FreeBSD13_VM_via_bhy= ve

On Oct 22, 2025, at = 10:03, void <void@f-m.fm> wrote:

Hi,

I wondered if = any work was happening to address the long-standing issue
of slow = vtnet? (in my case, this leads to slow freebsd guest performance
in = bhyve compared with every linux guest tested and OpenBSD).

I = thought maybe the recent bridge work may have ameliorated the problem = some, but testing, after configuring a (recent) stable/15 server to use = the ip-configured-on-bridge-method, showed no improvement using
a = (recent) stable/14 guest

[ ID] Interval =           Transfer =     Bitrate =         Retr
[  5] =   0.00-60.03  sec  3.17 GBytes   454 = Mbits/sec    0     sender
[ =  5]   0.00-60.03  sec  3.17 GBytes =   454 Mbits/sec =          receiver

for = comparison, an ubuntu 25.04 guest:

[ ID] Interval =           Transfer =     Bitrate =         Retr
[  5] =   0.00-60.00  sec  6.42 GBytes   919 = Mbits/sec  5427    sender
[  5] =   0.00-60.00  sec  6.42 GBytes   919 = Mbits/sec =          receiver

the = baremetal host

[ ID] Interval =           Transfer =     Bitrate =         Retr
[  5] =   0.00-60.01  sec  6.58 GBytes   941 = Mbits/sec    0     sender
[ =  5]   0.00-60.01  sec  6.58 GBytes =   941 Mbits/sec =          receiver

Test= s done a year and a half ago on similar hardware showing
the same = patterns http://void.f-m.fm.user.fm/bhyve-virtio-testing.html
-- =


Best Regards,
Cheng Cui



= --Apple-Mail=_77D438CE-EAF7-4AAD-AD97-D7A69CC54874--