[Performance] Samba 3 vs. Samba 4 performance in NetBench
jra at samba.org
Tue Jun 21 05:42:47 GMT 2005
On Tue, Jun 21, 2005 at 02:44:36PM +1000, Andrew Tridgell wrote:
> going on for hundreds of operations. I'm guessing the client is trying
> to force allocation of disk blocks. For Samba3 is skips these, as it
> thinks it only has to do one write every 1M to force allocation (in
> fact, Samba3 is lying and it does really need to do a write every 4k
> or so to force allocation, but the client doesn't know that).
That's exactly what it's doing. I recently had a reported Samba3 bug
where Word produced corrupted files because these 1 byte probes
didn't return "out of space" when a user was hitting out of quota
(it was a university). The fix was to add a parameter to force
smbd to write out the intervening bytes as zeros before doing the
1 byte write. That then causes the out of space error to be returned
at the correct time so MS-Office doesn't corrupt user files. Samba4
will have to have the same hack to be able to support quota-limited
shares where the admins need to catch this.
The code is found under the "strict allocate" code path in Samba3.
More information about the samba-technical