Kaleb Harper
2009-Apr-28 17:02 UTC
[Samba] linux -> windows special characters in filenames problems
I'm running Samba 3.32 on my linux server to share files with the windows computers on the network. My problem is that windows doesn't support some special characters in filenames, like ' : ', that linux has no problem with. So something (not sure if it's Samba or windows) is mangling directory/file names containing that character into 8.3 names, which makes it very difficult to know from windows what's in the directories; I'm having to open each directory to see the contents, which is quite an annoyance. Here's a couple of examples of how it's mangling directory names: 'this: is a test' is getting turned into 'THUKO5~M' 'this: is another test' is getting turned into 'TPYQ1X~Y' Since I suspect there's not an easy way to get windows to understand the ' : ' and various other characters that it probably doesn't understand properly, I was hoping there was a way to change the mangling to something more readable. I don't care if it removes the ' : ' completely, or changes it into some other character, I just want to be rid of the 8.3 names. I'm hoping that it's something that can be done from Samba so I don't have to reconfigure several windows computers, but I'll do whatever it takes if I have to :) I appreciate any help you all can give me.
John Drescher
2009-Apr-28 17:09 UTC
[Samba] linux -> windows special characters in filenames problems
On Tue, Apr 28, 2009 at 1:03 PM, Kaleb Harper <kaleb.tmp@gmail.com> wrote:> I'm running Samba 3.32 on my linux server to share files with the windows > computers on the network. My problem is that windows doesn't support some > special characters in filenames, like ' : ', that linux has no problem with. > So something (not sure if it's Samba or windows) is mangling directory/file > names containing that character into 8.3 names, which makes it very > difficult to know from windows what's in the directories; I'm having to open > each directory to see the contents, which is quite an annoyance. Here's a > couple of examples of how it's mangling directory names: > > > 'this: is a test' ? ?is getting turned into ? ? ? ?'THUKO5~M' > 'this: is another test' ? ? ? ?is getting turned into ? ? ? ?'TPYQ1X~Y' > > > Since I suspect there's not an easy way to get windows to understand the ' : > ' and various other characters that it probably doesn't understand properly, > I was hoping there was a way to change the mangling to something more > readable. I don't care if it removes the ' : 'It would have to : is an illegal character as a file or folder name in windows. This was a result of drive letters being c: d: ... John
Kaleb Harper
2009-Apr-28 17:16 UTC
[Samba] linux -> windows special characters in filenames problems
I just tried 'mangled names = No', it made the directory names appear properly, but when I try to open the directory, I get an error message that it can't access the folder. So I assume the only other way is going to be to somehow remove/change the ' : '. Any suggestions on how to do this would be helpful. If it's doable inside of Samba, that's great, if not, I'm not opposed to putting some kind of shell script on a cron to just go thru and rename everything with bad characters, but I'm afraid I don't know how to do that either :) On Tue, Apr 28, 2009 at 12:08 PM, Evans, Bill <bevans@fhcrc.org> wrote:> Try setting this in the share section in smb.conf > > mangled names = No > > > > Bill Evans > > > -----Original Message----- > From: samba-bounces+bevans=fhcrc.org@lists.samba.org > [mailto:samba-bounces+bevans <samba-bounces%2Bbevans>=fhcrc.org@ > lists.samba.org] On Behalf Of > Kaleb Harper > Sent: Tuesday, April 28, 2009 10:03 AM > To: samba@lists.samba.org > Subject: [Samba] linux -> windows special characters in filenames > problems > > I'm running Samba 3.32 on my linux server to share files with the > windows > computers on the network. My problem is that windows doesn't support > some > special characters in filenames, like ' : ', that linux has no problem > with. > So something (not sure if it's Samba or windows) is mangling > directory/file > names containing that character into 8.3 names, which makes it very > difficult to know from windows what's in the directories; I'm having to > open > each directory to see the contents, which is quite an annoyance. Here's > a > couple of examples of how it's mangling directory names: > > > 'this: is a test' is getting turned into 'THUKO5~M' > 'this: is another test' is getting turned into 'TPYQ1X~Y' > > > Since I suspect there's not an easy way to get windows to understand the > ' : > ' and various other characters that it probably doesn't understand > properly, > I was hoping there was a way to change the mangling to something more > readable. I don't care if it removes the ' : ' completely, or changes it > into some other character, I just want to be rid of the 8.3 names. I'm > hoping that it's something that can be done from Samba so I don't have > to > reconfigure several windows computers, but I'll do whatever it takes if > I > have to :) > > I appreciate any help you all can give me. > -- > To unsubscribe from this list go to the following URL and read the > instructions: https://lists.samba.org/mailman/options/samba >
Evans, Bill
2009-Apr-28 17:21 UTC
[Samba] linux -> windows special characters in filenames problems
Try setting this in the share section in smb.conf mangled names = No Bill Evans -----Original Message----- From: samba-bounces+bevans=fhcrc.org@lists.samba.org [mailto:samba-bounces+bevans=fhcrc.org@lists.samba.org] On Behalf Of Kaleb Harper Sent: Tuesday, April 28, 2009 10:03 AM To: samba@lists.samba.org Subject: [Samba] linux -> windows special characters in filenames problems I'm running Samba 3.32 on my linux server to share files with the windows computers on the network. My problem is that windows doesn't support some special characters in filenames, like ' : ', that linux has no problem with. So something (not sure if it's Samba or windows) is mangling directory/file names containing that character into 8.3 names, which makes it very difficult to know from windows what's in the directories; I'm having to open each directory to see the contents, which is quite an annoyance. Here's a couple of examples of how it's mangling directory names: 'this: is a test' is getting turned into 'THUKO5~M' 'this: is another test' is getting turned into 'TPYQ1X~Y' Since I suspect there's not an easy way to get windows to understand the ' : ' and various other characters that it probably doesn't understand properly, I was hoping there was a way to change the mangling to something more readable. I don't care if it removes the ' : ' completely, or changes it into some other character, I just want to be rid of the 8.3 names. I'm hoping that it's something that can be done from Samba so I don't have to reconfigure several windows computers, but I'll do whatever it takes if I have to :) I appreciate any help you all can give me. -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/options/samba
Jeremy Allison
2009-Apr-28 17:24 UTC
[Samba] linux -> windows special characters in filenames problems
On Tue, Apr 28, 2009 at 12:03:00PM -0500, Kaleb Harper wrote:> I'm running Samba 3.32 on my linux server to share files with the windows > computers on the network. My problem is that windows doesn't support some > special characters in filenames, like ' : ', that linux has no problem with. > So something (not sure if it's Samba or windows) is mangling directory/file > names containing that character into 8.3 names, which makes it very > difficult to know from windows what's in the directories; I'm having to open > each directory to see the contents, which is quite an annoyance. Here's a > couple of examples of how it's mangling directory names: > > > 'this: is a test' is getting turned into 'THUKO5~M' > 'this: is another test' is getting turned into 'TPYQ1X~Y' > > > Since I suspect there's not an easy way to get windows to understand the ' : > ' and various other characters that it probably doesn't understand properly, > I was hoping there was a way to change the mangling to something more > readable. I don't care if it removes the ' : ' completely, or changes it > into some other character, I just want to be rid of the 8.3 names. I'm > hoping that it's something that can be done from Samba so I don't have to > reconfigure several windows computers, but I'll do whatever it takes if I > have to :)There's no way to fix this within Samba. Names containing ":" are illegal on Windows machines, we have to mangle them. You'll have to change these names if you want the names to be seen correctly from Windows. Jeremy.
Haro de Grauw
2009-Apr-28 17:31 UTC
[Samba] linux -> windows special characters AND charset problem
Extension of this problem - I am experiencing the same as Kaleb, all file names that include Windows-unfriendly characters are displayed as apparently random eight-character names like "THUK05-M". But there's more - charsets don't seem to match. My setup: Samba 3.2.7 running on openSUSE 11.1 / KDE 4.1 / latest x86_64 XEN kernel. Home network with three WinXP boxes (sp3) - workgroup, so no PDC. Supposedly, all should talk UTF-8 over the network. Accessing shared directories works well in both directions (win <-> linux), although with the same problem as Kaleb. Furthermore, when I access a samba share from any XP machine, file/directory names on the Linux machine with non-ASCII characters e.g. "G? Reinders" will display wrongly, with box replacing '?'. I can copy the folder to the XP machine (this can be done from either end) and no error is given, and I can open the folder on the windows machine locally even though the name still "looks wrong" i.e. has that box character in it (of course, I can fix it manually from there, but that's not the point). When I then access the XP machine from the Linux machine, Konqueror gives an error message: File does not exist smb://winxp2/My%20Documents/G%EF%BF%BD%20Reinders It then displays the My Documents folder, showing "G? Reinders" with an icon indicating a protected file. If I click on it, I get the error: this file doesn't exist, and I can't open it. Now here's the funny thing: if I just type the path smb://winxp2/My Documents/G? Reinders into the Konqueror prompt, it opens flawlessly! testparm -v | grep "charset" on Linux machine returns: dos charset = CP850 unix charset = UTF-8 display charset = LOCALE Windows XP should talk UTF-8 over the network by default, right? Is there a way to check this? All help welcome and appreciated. Cheers, Haro Kaleb Harper schreef:> I'm running Samba 3.32 on my linux server to share files with the windows > computers on the network. My problem is that windows doesn't support some > special characters in filenames, like ' : ', that linux has no problem with. > So something (not sure if it's Samba or windows) is mangling directory/file > names containing that character into 8.3 names, which makes it very > difficult to know from windows what's in the directories; I'm having to open > each directory to see the contents, which is quite an annoyance. Here's a > couple of examples of how it's mangling directory names: > > > 'this: is a test' is getting turned into 'THUKO5~M' > 'this: is another test' is getting turned into 'TPYQ1X~Y' > > > Since I suspect there's not an easy way to get windows to understand the ' : > ' and various other characters that it probably doesn't understand properly, > I was hoping there was a way to change the mangling to something more > readable. I don't care if it removes the ' : ' completely, or changes it > into some other character, I just want to be rid of the 8.3 names. I'm > hoping that it's something that can be done from Samba so I don't have to > reconfigure several windows computers, but I'll do whatever it takes if I > have to :) > > I appreciate any help you all can give me. >