[Samba] directory list is not alphabetically sorted
Alain.Gorlier at altissemiconductor.com
Alain.Gorlier at altissemiconductor.com
Mon Jun 11 13:29:32 GMT 2007
Hi,
Created some files and directories on a Samba 3.0.22 Linux server from an
Windows Samba client using this chronological order :
cc
aa
zz
bb
yy
ww
rr
ss
tt (directory)
mm (directory)
oo (directory)
jj (directory)
The directory list on Windows Samba client (via dir command without any
options) shows the following:
Y:\toto>dir
Volume in drive Y is MXX
Volume Serial Number is 12E4-00F3
Directory of Y:\toto
11/06/2007 15:18 <DIR> .
11/06/2007 15:01 <DIR> ..
11/06/2007 15:01 12 zz
11/06/2007 15:18 <DIR> oo
11/06/2007 15:00 11 cc
11/06/2007 15:18 <DIR> jj
11/06/2007 15:04 9 rr
11/06/2007 15:18 <DIR> mm
11/06/2007 15:04 12 ss
11/06/2007 15:03 11 ww
11/06/2007 15:01 13 aa
11/06/2007 15:03 16 yy
11/06/2007 15:01 9 bb
11/06/2007 15:18 <DIR> tt
8 File(s) 93 bytes
6 Dir(s) 2 609 844 224 bytes free
Same behaviour with an OS2 Samba client.
Using an OS2 Lan server instead Linux Samba server, the dir command
without any option, show an alphabetically sorted list across files and
directories.
Some applications rely on this alphabetical order. (for good or bad
reasons...)
Is there a way to recover the same behaviour ?
Using the ls -l command on the linux fileserver, the directory list is
alphabetically sorted : (just what we want)
[B2:fsetssd1l1:root] > ls -l
total 48
-rwxrwxr-x 1 ADMINOCS shetssgrp 13 jun 11 15:01 aa
-rwxrwxr-x 1 ADMINOCS shetssgrp 9 jun 11 15:01 bb
-rwxrwxr-x 1 ADMINOCS shetssgrp 11 jun 11 15:00 cc
drwxrwxr-x 2 ADMINOCS shetssgrp 4096 jun 11 15:18 jj
drwxrwxr-x 2 ADMINOCS shetssgrp 4096 jun 11 15:18 mm
drwxrwxr-x 2 ADMINOCS shetssgrp 4096 jun 11 15:18 oo
-rwxrwxr-x 1 ADMINOCS shetssgrp 9 jun 11 15:04 rr
-rwxrwxr-x 1 ADMINOCS shetssgrp 12 jun 11 15:04 ss
drwxrwxr-x 2 ADMINOCS shetssgrp 4096 jun 11 15:18 tt
-rwxrwxr-x 1 ADMINOCS shetssgrp 11 jun 11 15:03 ww
-rwxrwxr-x 1 ADMINOCS shetssgrp 16 jun 11 15:03 yy
-rwxrwxr-x 1 ADMINOCS shetssgrp 12 jun 11 15:01 zz
Why does Samba & Linux not show the same order ?
Regards,
More information about the samba
mailing list