Samba caseinsensitive lookup benchmark

James Peach jamespeach at mac.com
Fri Apr 11 21:45:15 GMT 2008


On 11/04/2008, at 10:58 AM, Jeremy Allison wrote:
> On Thu, Apr 10, 2008 at 07:00:05PM -0700, James Peach wrote:
>> Hi Barry,
>>
>> I stumbled over the XFS CI patch thread. One of the reasons this  
>> might not
>> have shown any benchmark improvement is that Samba needs some minor  
>> fixes
>> to support case-insensitive filesystems better:
>>
>> <http://git.samba.org/?p=jpeach/samba.git;a=commitdiff;h=519dc6cf4acff10f2c10ca78114a8e0e8e0e46b1 
>> >
>>
>> I also have a smbtorture benchmark that I used to demonstrate the
>> performance benefit. There's not much advantage in most cases for
>> well-behaved client. The benchmark I wrote demonstrates that CI in  
>> the
>> filesystem should save us from really horrible performance in the  
>> lookup
>> failure case (and does on HFS+).
>>
>> I'll push it through open source review - should be upstream in  
>> about a
>> week.

I'm talking about the benchmark patch, not the case-insensitive  
filesystem fix. The latter is already review and released. If you want  
it, I can merge it any time.

> I'd like to discuss this one before you do that. You've added a
> fs_capabilities to the connection struct which looks ok, but
> then you split out the checks for (conn->fs_capabilities &
> FILE_CASE_SENSITIVE_SEARCH) separately from the same checks on
> if (conn->case_sensitive)

They are different things. fs_capabilities tells you the semantics  
that the filesystem is providing to Samba. The (conn)->case_sensitive  
flag tells you the semantics that the Samba is providing to the SMB  
client. I'm not sure wether this was the original intent of the latter  
flag, but that seems to be is implementation.

> - at least in some places in your
> patch (eg. your smbd/filename.c change). These should be
> identical - in fact we should probably replace all these
> checks with an :
>
> FS_IS_CASE_INSENSITIVE(conn) (((conn)->fs_capabilities &
> FILE_CASE_SENSITIVE_SEARCH) || (!(conn)->case_sensitive))

Yeh, that looks reasonable.

>
>
> macro instead, and just use that as the one check.
>
> Jeremy.



More information about the samba-technical mailing list