In recent versions of Samba (including 3.0.24), attempting to rename a
file to a new name that differs only in case appears to have no effect:
X:\tmp>echo . > FILE.txt
X:\tmp>dir
02/05/2007 08:21p 4 FILE.txt
X:\tmp>ren FILE.txt file.txt
X:\tmp>dir
02/05/2007 08:21p 4 FILE.txt
I'm pretty sure this worked in older versions.
Any ideas?
Thanks.
--
Jordan Russell
--
To unsubscribe from this list go to the following URL and read the
instructions: https://lists.samba.org/mailman/listinfo/samba
cheerz
Jordan Russell wrote:
> Server OS: Linux / Fedora Core 6
> Samba version: 3.0.24, 3.0.23 (binary packages for FC6)
> Samba configuration: All defaults
> Client OS: Windows XP SP2, Windows 2000 SP4
>
> In recent versions of Samba (including 3.0.24), attempting to rename a
> file to a new name that differs only in case appears to have no effect:
>
> X:\tmp>echo . > FILE.txt
>
> X:\tmp>dir
> 02/05/2007 08:21p 4 FILE.txt
>
> X:\tmp>ren FILE.txt file.txt
>
> X:\tmp>dir
> 02/05/2007 08:21p 4 FILE.txt
>
> I'm pretty sure this worked in older versions.
> Any ideas?
>
> Thanks.
>
--
Michael Gasch
Max Planck Institute for Evolutionary Anthropology
Department of Human Evolution (IT Staff)
Deutscher Platz 6
D-04103 Leipzig
Germany
Phone: 49 (0)341 - 3550 137
49 (0)341 - 3550 374
Fax: 49 (0)341 - 3550 399
As mentioned, I'm using all defaults. Grepping for "case" in smb.conf
doesn't yield any matches.
Note that I am able to create new files with all-lowercase letters. I
just can't rename an existing "FILE.txt" to "file.txt".
--
Jordan Russell
Jordan Russell wrote:
> In recent versions of Samba (including 3.0.24), attempting
> to rename a file to a new name that differs only in
> case appears to have no effect:
If it did ever work, it was a fluke. Renaming
files to different case on a caseless filesystem
(or filesystem protocol) doesn't make much sense.
cheers, jerry
=====================================================================
Samba ------- http://www.samba.org
Centeris ----------- http://www.centeris.com
"What man is a man who does not make the world better?" --Balian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFybQgIR7qMdg1EfYRAj7ZAKDd/nzgFerB6wn0K+zK8PS4dKlJxgCg81Jc
WDYYJc9xgyX56HQ4VUEqavM=
=wgrk
-----END PGP SIGNATURE-----
>From what client?
MS Windows doesn't distinguish between those two names, so it won't let
you perform the re-name as it thinks you're not changing the name.
You can do it in Windows as a two-step process:-
Rename FILE.txt to anything.txt
Rename anything.txt to file.txt
Oh the joys of Windows.....
Mac
Assistant Systems Administrator @nibsc.ac.uk
m...@nibsc.ac.uk
Work: +44 1707 641565 Everything else: +44 7956 237670 (anytime)
Erm, why would it be a "fluke"? You can do this on local filesystems (as
far back as Windows 95, at least), and you can do this on shares exposed
by Windows servers. Only when talking to a (recent) Samba server does it
fail to rename the file.
(How I noticed this problem: I have an rsync-like program that mirrors
the contents of a local directory to a remote system. One thing it
checks for is discrepancies in the case of filenames; if it finds any,
it corrects them. This feature works on Windows servers, and up until
recently, I'm fairly certain that it worked on Samba servers as well.
Now, when talking to Samba servers, the program just finds more and more
case discrepancies each time it runs, because it can never correct them.)
--
Jordan Russell
Jordan Russell wrote:
> Gerald (Jerry) Carter wrote:
>> If it did ever work, it was a fluke. Renaming
>> files to different case on a caseless filesystem
>> (or filesystem protocol) doesn't make much sense.
>
> Erm, why would it be a "fluke"? You can do this on
> local filesystems (as far back as Windows 95, at least), and
> you can do this on shares exposed by Windows servers.
> Only when talking to a (recent) Samba server does it
> fail to rename the file.
File a bug please. Although in ge grand scheme of things
this would be low priority to me. Maybe Jeremy feels differently.
He lives in the file serving code more than I do.
cheer,s jerry
=====================================================================
Samba ------- http://www.samba.org
Centeris ----------- http://www.centeris.com
"What man is a man who does not make the world better?" --Balian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFFyhs+IR7qMdg1EfYRAjw9AKDs+QDg+XykJ1Dgzfg3FPxiMxsHagCfaSQM
DsFDNFnHkaxfFbVKL/XIj8M=
=CZiE
-----END PGP SIGNATURE-----
No, someone did log a bug on this once and I did
fix it :-). The thing to do is test with smbclient
to see if my fix still works - Windows exporer
canonicalizes the name so you can't use that.
Jeremy.
That's actually not true; Windows-hosted filesystems allow it.
--- Test on local Windows 2000 file system ---
C:\>echo . > FILE.txt
C:\>dir
02/07/2007 12:11p 4 FILE.txt
C:\>ren FILE.txt file.txt
C:\>dir
02/07/2007 12:11p 4 file.txt
--- Test on remote share hosted by Windows 2000 server ---
J:\>echo . > FILE.txt
J:\>dir
02/07/2007 12:12p 4 FILE.txt
J:\>ren FILE.txt file.txt
J:\>dir
02/07/2007 12:12p 4 file.txt
--
Jordan Russell
Okay, done:
https://bugzilla.samba.org/show_bug.cgi?id=4377
--
Jordan Russell
I've just fixed this in SVN. Turns out it was side-effect
breakage when we turned on root dfs by default. That was
a fun one - allowed me to clean up some old DFS code :-).
Jeremy.
Excellent. Thanks!
--
Jordan Russell
> On Mon, Feb 05, 2007 at 09:33:35PM -0600, Jordan Russell wrote:
>>
>> In recent versions of Samba (including 3.0.24), attempting to rename a
>> file to a new name that differs only in case appears to have no effect:
>>
>> I'm pretty sure this worked in older versions. Any ideas?
>
> I've just fixed this in SVN. Turns out it was side-effect breakage when we
> turned on root dfs by default. That was a fun one - allowed me to clean up
> some old DFS code :-).
>
> Jeremy.
I noticed the problem and came across this thread after some searching.
Is it correct that the fix will be in 3.0.25 but not in 3.0.24? So, if I
want to correct the problem now, I would need to compile samba from source
with the patched msdfs.c ?
Akemi
Don't - I'm in the middle of re-writing a lot of
the DFS code for 3.0.25. There's no guarentee that
what is in the tree right now will look anything
like the DFS code in the tree by the end of the
weekend (if my tests go well).
I'll let you know when it's stabilized enough to
pull a fix.
Thanks,
Jeremy.