[Samba] directory list is not alphabetically sorted

Mark J. Reed markjreed at mail.com
Thu Jun 14 17:04:29 GMT 2007


Am I to infer from this discussion that the Windows equivalent of
readdir() always returns its entries in sorted order?  Explorer and
CMD.EXE don't do that themselves?

And can't your users just use the "Arrange Icons By" feature of the
context menu?

On 6/14/07, Jeremy Allison <jra at samba.org> wrote:
> 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.
> --
> To unsubscribe from this list go to the following URL and read the
> instructions:  https://lists.samba.org/mailman/listinfo/samba
>


-- 
Mark J. Reed <markjreed at mail.com>


More information about the samba mailing list