[Samba] Question about Case Insensitivity
kstailey at yahoo.com
Thu Oct 26 22:56:06 GMT 2006
--- Kenneth Stailey <kstailey at yahoo.com> wrote:
> I am trying to make a Linux filesystem appear case-insensitive and I got the
> idea that I could use a SAMBA loopback mount to do this. I almost succeeded
> on my first try but I ran into a snag I have no answer for yet.
> My setup involves sharing filesystem "/a" and then mounting it on "/b". I
> can use "ls -l" on the "/b" filesystem in a case-insensitive fashion but
> when I go to open the file by a case-insensitive name the attempt fails.
> Can someone please explain why I am not able to open() files with case
> insensitive names even though stat() or lstat() works with them?
> These examples illustrate my issue:
> Case sensitive ext3 filesystem:
> # ls -l /a/AbCd/EFgh
> -rw-r--r-- 1 root root 6 Oct 24 10:18 /a/AbCd/EFgh
> # ls -l /a/abcd/efgh
> ls: /a/abcd/efgh: No such file or directory
> Case insensitive mount.cifs mount of SAMBA shared "/a" filesystems:
> # ls -l /b/AbCd/EFgh
> -rw-r--r-- 1 root root 6 Oct 24 10:18 /b/AbCd/EFgh
> # ls -l /b/abcd/efgh
> -rw-r--r-- 1 root root 6 Oct 24 10:18 /b/abcd/efgh
> But why doesn't open(2) work in a case insenstive fashion?
> # cat /b/AbCd/EFgh
> # cat /b/abcd/efgh
> cat: /b/abcd/efgh: No such file or directory
Once I stopped using mount.cifs all the pain in the diodes down my left side
# mount -t smbfs -o username=root //localhost/public /b
# cat /b/abcd/efgh
The moral of the story is that mount.cifs sucks and mount.smbfs rules!
More information about the samba