KIP, Powerprint Request software -samba

Martin Zielinski mz at seh.de
Fri Aug 13 08:25:44 GMT 2004


Hello,
I took a look at this interesting problem (Samba 3.0.4). 
Tracing the situation with ethereal shows, that the application requests a 
directory listing and after that calls a "FIND_FIRST2" request for each file 
in the listing. So there is no opening and reading of files or whatever.
The behaviour is the same with Samba or a windows box.

Comparing the trace from Samba to Windows shows, that the response times to 
these requests increase massively on Samba with the number of files in the 
directory, while the response time stays allmost constant on windows:

Windows: 4000 files ~0.0005 seconds, 50 files ~0.0005 seconds
Samba: 4000 files ~0.004 - 0.005 seconds, 50 files ~ 0.0004 seconds

So Samba needs (4000 files) about 20 seconds only for the responses, Windows 2 
seconds.

The response times are also related to the place in the directory listing:
I named my 4000 files 0-3999 and the responses to the lower numbered files are 
quicker than the responses to requests on the higher numberd files.

Looks, like Samba searches linear directory listings for each request on one 
file ??.

This is part of a level 10 log using 5 files in the directory:

[...]
call_trans2findfirst: dirtype = 22, maxentries = 1366, close_after_first=1, 
close_if_end = 1 requires_resume_key = 1 level = 0x104, max_data_bytes = 
16384
unix_convert called on file "2"
stat_cache_lookup: lookup failed for name [2]
stat_cache_add: Added entry 2 -> 2
conversion finished 2 -> 2
is_in_path: 2
is_in_path: no name list.
dir=./, mask = 2
start_dir dir=./
is_in_path: ./
is_in_path: no name list.
is_in_path: 0
is_in_path: no name list.
is_in_path: 1
is_in_path: no name list.
is_in_path: 2
is_in_path: no name list.
is_in_path: 3
is_in_path: no name list.
is_in_path: 4
is_in_path: no name list.
creating new dirptr 256 for path ./, expect_close = 1
dptr_num is 256, wcard = 2, attr = 22
dirpath=<./> dontdescend=<>
[...]
call_trans2findfirst: dirtype = 22, maxentries = 1366, close_after_first=1, 
close_if_end = 1 requires_resume_key = 1 level = 0x104, max_data_bytes = 
16384
unix_convert called on file "3"
stat_cache_lookup: lookup failed for name [3]
stat_cache_add: Added entry 3 -> 3
conversion finished 3 -> 3
is_in_path: 3
is_in_path: no name list.
dir=./, mask = 3
start_dir dir=./
is_in_path: ./
is_in_path: no name list.
is_in_path: 0
is_in_path: no name list.
is_in_path: 1
is_in_path: no name list.
is_in_path: 2
is_in_path: no name list.
is_in_path: 3
is_in_path: no name list.
is_in_path: 4
is_in_path: no name list.
creating new dirptr 256 for path ./, expect_close = 1
dptr_num is 256, wcard = 3, attr = 22
dirpath=<./> dontdescend=<>
[...]

This will be similar with 4000 files.

I hope, someone of you gurus can do something with this information.

Greetings,

Martin

On Thursday 12 August 2004 02:13, Mark Nehemiah wrote:
> On Wed, August 11, 2004 5:57 pm, Jeremy Allison said:
> > I probably won't have time this week (cifs conference).
> > Others network performance problems are always
> > hard to debug from a distance. It doesn't look like a
> > particular Samba issue.
> >
> > Jeremy
>
> Wow, ::severely embarrassed look:: I'm ashamed to say, I forgot it(cifs
> conference) was going on.  Hopefully in a positive direction for Samba.
> Thanks for your time,  go have a beer for me.   I do need to see if I can
> do something about this sometime, so I'll work on it and see if I can
> figure it out.  If I see anything or have some questions, I may post a
> link of some packet info to the list and see if anyone can help.  I
> wouldn't be surprised if it is the Vendors software being stupid.
>
>         Thanks,
>                    Mark

-- 
Martin Zielinski                       mz at seh.de
Software Development
SEH Computertechnik GmbH     www.seh.de


More information about the samba-technical mailing list