LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-06-2013, 07:18 AM   #1
jmjimenezt
LQ Newbie
 
Registered: Feb 2013
Posts: 1

Rep: Reputation: Disabled
Angry Unrecognized characters in folder names in folders created via Putty


Hi there!

I don't know whether this is the correct place for this post... Anyway:

I'm facing a problem that is driving me crazy:

Imagine that I have a Linux server and there are several clients that use Putty (from a Windows machine) to connect with the Linux server and create directories (could be files as well) with "mkdir".

The problem is that, with Putty, you can use any encoding (CP1250..., ISO-'s, etc) and if you introduce "non-standard" characters like ö, ä, ü (for German for example), later, using the terminal inside the Linux server (UTF-8), I cannot browse into those folder, since these characters are not well recognized.

(I was able to reproduce this problem using a Linux VM in a Windows environment and using Putty with different encodings to connect it.)

Any ideas of what can I do? Any clue?

I created a Python script to try to recognize the encoding what it is not accurate 100%. I know I can use convmv to change the encoding of the folder name but I need to know first which encoding was used.

Thanks in advance!
 
Old 02-06-2013, 07:38 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,901

Rep: Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318Reputation: 7318
http://www.samba.org/samba/docs/man/...O/unicode.html
probably you can try something like this:
dos charset = <I do not know>
unix charset = ascii
But i'm not really sure. Also you can use a cronjob or process to rename files, but in that case users will report missing/lost files.
 
Old 02-06-2013, 08:15 AM   #3
shivaa
Senior Member
 
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
Is locale setting same for both your Windows system and Linux server?

Can you once try to open any of those directories in this way:-
Just type first 1 or 2 or 3 characters of a directory name and hit tab key from the keyboard. Linux shell will then automatically insert bachslashes (\) before any special characters in dir. name.
Code:
~$ cd sam[tab]
~$ pwd
sample
Second, if any file/dir. name has some special or unrecognized characters, then you can put the file/dir. name in double-quotes like:
Code:
~$ cd "s@mple file"
Although this is just based on my experience, but you can try it. If it don't help, then share some file/name as it's showing in Linux.
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Script to delete folders (whose names are in format XXXmmdd) but leave latest folder AntBla Linux - Newbie 4 10-04-2012 03:41 AM
Why are no application folders being created in home folder? usernameinuse Linux - Newbie 3 06-15-2010 02:25 AM
Need to rename files and folders with invalid characters in the names laureynsr Linux - Newbie 5 04-01-2009 03:13 PM
Can't cd into created folders in Documents Folder either on Desktop or in File System bparkerson04 Linux - Newbie 2 01-20-2009 12:44 AM
Can i limit new file names created to 8 characters with samba ? amitsharma_26 Linux - Networking 1 12-16-2005 05:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:12 PM.

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