Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] smbfs & kana/kanji



On Fri, 2003-08-01 at 20:58, Neil Bortnak wrote:
> Hi,
> 
> I don't think that's it. Most of my tests were conducted on the Japanese
> version of knoppix which displays the kana just fine. Also, at least
> some portion of the filenames were being received as question marks
> directly from the server because unicode transport failed for one reason
> or another.
> 
> Do you have kana displayed on filenames you are accessing over a
> CIFS/SMB link to a non-samba server? I would have thought this to be an
> amazingly common setup

I will try to explain how to get Japanese samba shares working.

Firstly, filenames can be encoded in a range of character sets EUC_JP
JIS, Shift_JIS, Unicode etc.  You need to know which one your filenames
are encoded in.  This can be done by listing them using ls in a terminal
that supports multiple character sets e.g. gnome-terminal

#LANG=ja_JP gnome-terminal

set the encoding to EUC-JP using the menu

テーミナル>Character Coding>EUC-JP

#ls  --show-control-chars 

if the characters display they are in EUC-JP.  Step thought the
encodings till you get a match.  This is the encoding used to store the 
file names on your Linux box. For samba purposes Unicode is probably the
best choice because samba my have some problems with other encodings.

To the best of my knowledge windows will always use Shift_JIS to encode
Japanese filenames.

Samba will do the conversion automatically for you if you set.

        coding system = UTF8
        client code page = 932

where UTF8 is the character set of the Linux filenames. It is explained
in the smb.conf man page.
from the manual

coding system (G)
	This parameter is used to determine how incoming Shift-JIS 	Japanese
characters are mapped from the incoming client code 	page used by the
client, into file names in the UNIX filesystem.
        Only  useful  if client code page is set to 932 (Japanese Shift-
        JIS). The options are
 
With this set correctly the filenames should display correctly under
Windows and Linux.

Edward Middleton

Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links