[Samba] linux -> windows special characters AND charset problem

Haro de Grauw bin at harodegrauw.net
Tue Apr 28 17:24:45 GMT 2009

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

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.

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.

More information about the samba mailing list