Re: Very slow scp performance comparing to Linux
- In reply to: Wei Hu : "RE: Very slow scp performance comparing to Linux"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 29 Aug 2023 08:28:57 UTC
On 8/29/23, Wei Hu <weh@microsoft.com> wrote:
>
>
>> -----Original Message-----
>> From: Guido Falsi <mad@madpilot.net>
>> Sent: Monday, August 28, 2023 6:49 PM
>> To: Wei Hu <weh@microsoft.com>; Mikhail Zakharov
>> <zmey20000@yahoo.com>; freebsd-hackers@freebsd.org
>> Subject: Re: Very slow scp performance comparing to Linux
>>
>> On 28/08/23 12:03, Wei Hu wrote:
>> > Hi Mike,
>> >
>> > All VMs are with same type and they are in Azure. If the copy on Linux
>> > is
>> being cached on the RX side, so is FreeBSD?
>> >
>>
>> You could perform the test using files in memory filesystems (tmpfs or
>> the
>> like). This would factor out disk performance whatever the backend.
>>
> Thanks, Guido. I tried tmpfs on the RX side with both FreeBSD and Linux VMs.
>
> The throughput on FreeBSD went up significantly from 50 MB/s to 630 MB/s
> with
> NIC interface. Linux went up modestly form 550 MB/s to 660 MB/s.
>
> So, looks in the non-tmpfs case, the Linux ext4 filesystem does cache large
> amounts
> of data in memory, much larger than FreeBSD ufs.
>
> Many thanks, Mike for bringing this up and Guido, for the suggestion to try
> tmpfs.
>
There is probably something funky going on here.
Here is a hack which will collect basic profiling info, works in a vm:
dtrace -w -n 'profile:::profile-4999 { @[sym(arg0)] = count(); }
tick-10s { system("clear"); trunc(@, 40); printa("%40a %@16d\n", @);
clear(@); }'
so start scp, start dtrace and see what happens
--
Mateusz Guzik <mjguzik gmail.com>