LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-10-2005, 11:04 PM   #1
stutterbug
LQ Newbie
 
Registered: Dec 2004
Location: Osaka, Japan
Distribution: RedHat 8.0
Posts: 20

Rep: Reputation: 1
Question Putty and Japanese encodings


I am building a bilingual Japanese-English website and I am connecting to my own server (RedHat 8.0) with Putty. VSFTPd has no problem accepting and HTTPd has no problem serving files that have been encoded in Japanese (Shift_JIS and UTF-8). Internally, RH is treating these files just fine. But either at the command prompt locally or via Putty, I cannot enter Japanese characters directly (for instance with EMACS). Likewise, I cannot see the Japanese characters in files that have been previously sent via FTP. These files serve up just fine to a browser, they get garbled when rendered in Putty (by 'garbled' I mean they get rendered in, I think, the ASCII representation of Unicode, for example \200Ä).

From Putty's documentation, there is no problem using Asian (or other) character encodings. You simply choose the appropriate system in their 'translation' settings. I have installed Japanese as a language during set-up, (though I did not install KDE or Gnome as this was built simply to be a remote server) and I am confident that the server is capable of accepting Japanese input if I were running in a graphical shell.

I suspect I can change things in the /etc/sysconfig/i18n file, but I am not sure what to insert or change. At present, I have:

Code:
[andrew@localhost html]$ cat /etc/sysconfig/i18n
LANG="en_US.UTF-8"
SUPPORTED="en_US.UTF-8:en_US:en:ja_JP.eucJP:ja_JP:ja"
SYSFONT="latarcyrheb-sun16"
Does anyone know how to get Japanese (or any other Asian font) working at a prompt or via SSH?

Andrew
Osaka
 
Old 01-15-2005, 03:53 AM   #2
stutterbug
LQ Newbie
 
Registered: Dec 2004
Location: Osaka, Japan
Distribution: RedHat 8.0
Posts: 20

Original Poster
Rep: Reputation: 1
Answer...

Answering my own post. I hope this helps someone.

Turns out that PuTTY does not support Japanese character encodings out of the box regardless of what anyone says about how it works with any encoding you have installed on your machine. You need to modify the program to get it working in Nihongo. I was able to download a modified version of the code from a Japanese site and I am connecting to my box correctly and viewing and editing files as I need. I got the patch from http://www007.upp.so-net.ne.jp/bemax/arita/putty.html . In the event the site changes, the file containing the patch is called "putty056_jpini_patch.zip" and it modifies the program to access a language file called, "puttyjp.lng". Go google if you don't find what you are looking for. I expect the file name will change as PuTTY's version number changes, so be flexible.

The site mentioned above is in Japanese and any page linking to it will likely be in Japanese too. My Japanese is quite poor, but I was able to get thing going pretty easily. You can either apply the patch and recompile the program from PuTTY's source (download off the PuTTY site) or download the executable and language file directly. The version of this file is the same as a trojan-loaded one that was famously on Download.com for two weeks, so be warned. Furthermore...

**WARNING: PuTTY is a secure client from a trustworthy source. Even if the source of the code is honest and decent (which it may not be), patching the code may introduce weaknesses to the program that you would not like. Be cautious and use this only if you have no other option.**

That said, I am running the program as we speak and I haven't seen anything unusual. But I have my fingers crossed. And typing with fingers crossed is more difficult than you can imagine.

Ganbatte ne!

Andrew
 
Old 07-01-2010, 11:30 PM   #3
GreenGuy
LQ Newbie
 
Registered: Jul 2010
Posts: 2

Rep: Reputation: 0
Question So, what was the solution?

Hi:
Hajimemashite!

I sure hope you are still on, stutterbug. I'm struggling with the same problem, communicating with a Fedora Linux system running some Japanese programs. My only access to the machine is via SSH.

I found puttyjp.exe, and have started creating a puttyjp.lng file so that the interface is back to English. I've also tried several received data character sets, but none of those work.

What character set did/do you use?
What other settings do you need to make?
Are there any specific settings needed on the Linux side?
Any other suggestions would be greatly appreciated.

ありがとう!
 
Old 07-02-2010, 12:05 AM   #4
stutterbug
LQ Newbie
 
Registered: Dec 2004
Location: Osaka, Japan
Distribution: RedHat 8.0
Posts: 20

Original Poster
Rep: Reputation: 1
Yikes! That was five years ago. I've moved to Mac, whose BSD-style shell and built-in Japanese support solves all these ridiculous problems. I think that PuTTY's moved on and made it easier to integrate CJK, but I have no specific advice. There are a couple of pages on setting up PuTTY for Japanese: http://www.umiacs.umd.edu/~aelkiss/xml/displaywin.html, and http://anti.teamidiot.de/nei/2007/02...n_unicode_utf/ (this last one applies specifically to UTF-8, but you could apply it to any character encoding scheme, I think).

A quick google of "Putty 日本語" brings up some older pages that reference the present version of Putty (0.60) and an accompanying patch. For example, http://yebisuya.dip.jp/Software/PuTTY/. Might be worth trying. But like I said in my original answer, try to avoid patching PuTTY. It's job is to protect your security and patching it with code from an unknown source pretty much trashes that.

In addition, about all I can advise you is: 1) make sure you know which character set your server is using (if it's in Japan, it typically is EUC, ISO-2202-JP, or Shift-JIS on older systems and UTF-8 on newer ones) and stick to that for anything that touches the server including how you save files locally and how you connect to the server); 2) make sure Japanese input/output is supported natively in your OS (seeing how you posted hiragana in your reply, it looks like you do); and then 3) and try testing out a variety of character encoding schemes by saving some Japanese text in a variety of encodings on your Windows box and upload them to your server via FTP -- then try viewing them through PuTTY to see if they each display properly. This last step shouldn't be necessary but it may point out if the server has an issue with any specific encoding.

Good luck!
 
1 members found this post helpful.
Old 07-02-2010, 11:15 AM   #5
GreenGuy
LQ Newbie
 
Registered: Jul 2010
Posts: 2

Rep: Reputation: 0
Thumbs up

Thanks!

I found this link:

http://hp.vector.co.jp/authors/VA024...jp20070603.zip

It's more recent than the one I'd found earlier. The puttyjp.lng file works -- just set the default language to English. The device I'm talking to uses "EUC-JP/AUTO DETECT JAPANESE". I'll have to see about working with EUC-JP encoded files under Windows.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to use iso8859-2 encodings for characters in GNOME 2.6 Rajahuroman Linux - Software 2 05-04-2009 08:50 AM
character encodings sharapchi Slackware 3 05-15-2008 08:20 AM
MySQL, Perl, Encodings ivanatora Programming 1 02-24-2005 06:56 AM
Re: Putty unixfreak Linux - Newbie 6 09-01-2004 11:42 AM
Other than putty KaktusKnight Linux - General 4 05-07-2003 01:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration