[Samba] directory list is not alphabetically sorted

Jeremy Allison jra at samba.org
Thu Jun 14 16:52:13 GMT 2007


On Thu, Jun 14, 2007 at 06:32:48PM +0200, Alain.Gorlier at altissemiconductor.com wrote:
> 
> Since we have Windows and OS2 application viewers of huge directories, it 
> impacts our users.
> They have now to scroll big number of pages or use search functions with 
> patterns multiple times.
> There are not critical applications, but it is a bit of pain for users.
> 
> Anyway, is there a rule of the way samba server lists filenames ? 
> If we stop/start samba server, the directory list order is kept, so it 
> sounds like there is a rule, but which ?

Samba simply returns names as seen in the readdir order - we don't
ever read the entire directory into memory (we used to but this was
a disaster for performance in large directories).

It's possible we could add a parameter to sort the slice of the
directory we're currently processing, but I'm not going to write
this patch - but I will review it if someone else does.

Jeremy.


More information about the samba mailing list