[Samba] Small file performance

John Gardeniers jgardeniers at objectmastery.com
Mon Jan 9 21:24:35 UTC 2017


Hi Volker,

Thanks for the response. The clients are Win 7, Win 10 and various 
flavours of Linux, with Samba client versions ranging from 3.6 to 4.5.3. 
There is no perceptible difference between any of them.

Network latency is never above 0.2s and mostly sits at around 0.1s. If 
that's a problem it is so only for Samba.

I did as you suggested with the smb options but that just made it worse. 
Using the same test environment and file set, the final speed dropped 
from average of around 3.5MB/s to an average of about 3.0MB/s over a 
series if test runs. Again, the OS, and therefore the client version, 
made no difference. I guess I won't be using those settings in production.

regards,
John


On 09/01/17 18:00, Volker Lendecke wrote:
> On Mon, Jan 09, 2017 at 09:39:31AM +1100, John Gardeniers via samba wrote:
>> We are experiencing painfully slow performance when transferring many small
>> files via Samba. We are currently running Samba 4.5.1, although based on my
>> searches the version doesn't seem to make any difference and this is a long
>> standing problem.
> SMB performance critically depends on the client. What client are you
> using?
>
>> Based on my searches I've been playing around with a number of settings. The
>> testbed right now has the following options added to the basic smb.conf:
>>
>>          socket options = TCP_NODELAY IPTOS_LOWDELAY SO_RCVBUF=32768
>> SO_SNDBUF=32768
>>          read raw = yes
>>          write raw = yes
>>          strict locking = no
>>          min receivefile size = 16384
>>          use sendfile = yes
>>          aio read size = 16384
>>          aio write size = 16384
>>          strict allocate = yes
> Just get rid of all these options, in particular the socket options.
> Replace them with
>
> aio read size = 1
> aio write size = 1
>
> and that's it.
>
> What't your network latency (ping time)? That's a lot more critical
> than raw bandwidth.
>
> Volker
>
> ______________________________________________________________________
> This email has been scanned by the Symantec Email Security.cloud service.
> For more information please visit http://www.symanteccloud.com
> ______________________________________________________________________




More information about the samba mailing list