Re: Avoiding the lagg(4) bottleneck

From: Doug McIntyre <merlyn_at_geeks.org>
Date: Mon, 21 Apr 2025 13:17:57 UTC
On Sun, Apr 20, 2025 at 07:48:09PM -0600, Brett Glass wrote:
> I've been attempting to expand the capacity of the connection between a
> FreeBSD machine and a switch by using the lagg(4) device to aggregate two
> gigabit ports.
> 
> Unfortunately, I'm running into a bottleneck. Perhaps due to the overhead of
> the driver, or limits on multithreading, or locks within the system, I can't
> get anywhere near 2 Gbps out of the pair of gigabit ports.

How are you testing?

With LAG, any single connection is still limited by the 10G link
speed. You can only get aggregate increased throughput with LAG with
multiple connections, multiple streams of data.

But if you've only got one stream (ie. copying one file from server to server), you
are still limited by the single link speed. But it will aggregate more, the
more streams, the more it can be load balanced over the LAG segments.