Topic "unicode filenames, "cannot find the file specified", odd beh"

Author Message
TS

Guest


I read http://winscp.net/eng/docs/faq_utf8, and if I understand it right, WinSCP should be able to transfer and synchronize files with unicode names even though they may not display correctly. Is that right?

I am trying to copy (sftp) a file from A to B (both Windows machines). The destination directory is empty and there are no spaces in the directory path. If the filename contains either a μ (U+0x03BC) or µ (U+0x00B5) character, WinSCP (this is 4.1.8 b415 on WinXP) copies the file then asks "Remote file 'Foo 1µV.dat' already exists. Overwrite?" Since the directory was empty, there is nothing to overwrite and this is unexpected behavior. Regardless of the answer given -- even append -- the file appears to transfer correctly.

When trying to copy a file from A to B where the destination directory path has a space in it, files with µ (U+0x00B5) transfer correctly -- without asking about overwriting the file. Files with μ (U+0x03BC) will not transfer, reporting "System Error. Code 2. The system cannot find the file specified."

Further, if two files are transferred together or in series, one named 'Foo 1µV.dat' (U+0x00B5) and another 'Foo 1μV.dat' (U+0x03BC), the second file transferred will incorrectly overwrite the former, instead of creating a new file as it should.

If both versions of the filename already exist on the server, WinSCP always downloads the U+0x00B5 version, even if the U+0x03BC file was selected. This means a filename containing μ (U+0x03BC) cannot be transferred from the server, throwing "No such file or directory. Error code: 2. Error message from server (en): SfsStatusCode.NoSuchFile. Request code: 3."

Other sftp clients connecting to the same server, have no issues with any of the above scenarios.
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
TS wrote:
I read http://winscp.net/eng/docs/faq_utf8, and if I understand it right, WinSCP should be able to transfer and synchronize files with unicode names even though they may not display correctly. Is that right?

Not completely. It work only as long as converting unicode name to local ansi encoding and back does not corrupt the file name. If it does, you will be behaviour which you describe.

Quote:
I am trying to copy (sftp) a file from A to B (both Windows machines). The destination directory is empty and there are no spaces in the directory path. If the filename contains either a μ (U+0x03BC) or (U+0x00B5) character, WinSCP (this is 4.1.8 b415 on WinXP) copies the file then asks "Remote file 'Foo 1V.dat' already exists. Overwrite?" Since the directory was empty, there is nothing to overwrite and this is unexpected behavior. Regardless of the answer given -- even append -- the file appears to transfer correctly.

Except for this. I have no explanation. Can you provide me your email address, so I can send you a debug version of WinSCP to track the problem? If you do not want to post the address here, you can send me an email. You will find it (if you log in) in my forum profile. Please include link to this topic. Thanks.
_________________
Martin Prikryl
TS
[View user's profile]

Joined: 2008-12-09
Posts: 8
Hm. Even after creating a login, I don't see your email on your profile page. But I found an email and sent (hopefully) you a message.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
TS wrote:
Hm. Even after creating a login, I don't see your email on your profile page. But I found an email and sent (hopefully) you a message.

Sorry, I haven't received anything. Please check the profile again. The address is obviously there Wink
_________________
Martin Prikryl
kenlo

Guest


Hi, I have a similar problem when copying files between WinXP and Ubuntu Hardy with v4.1.8 (build 415).

If a filename have "?" in it, it can't be copied though everything is perfectly OK under the respective file managers. WinXP -> Hardy "system error code 123" will popup. The other way round, "a call to an OS function failed" will popup.

No "?" in the filename - it can be copied but cannot retain the filename. The new filename will have "?" in it. And Hardy will append "(invalid encoding)" to the filename.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
kenlo wrote:
Hi, I have a similar problem when copying files between WinXP and Ubuntu Hardy with v4.1.8 (build 415).

If a filename have "?" in it, it can't be copied though everything is perfectly OK under the respective file managers. WinXP -> Hardy "system error code 123" will popup. The other way round, "a call to an OS function failed" will popup.

No "?" in the filename - it can be copied but cannot retain the filename. The new filename will have "?" in it. And Hardy will append "(invalid encoding)" to the filename.

What protocol?
_________________
Martin Prikryl
kenlo

Guest


sftp
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
kenlo wrote:
sftp

OK, so I suppose that your server is OpenSSH, right?
OpenSSH does not announce support of UTF-8. If your server uses UTF-8 natively, you need to force WinSCP to use it. Please read FAQ.
kenlo

Guest


Thank you. Apology for my oversight of the FAQ. It is now perfectly OK.
popins

Guest


TS wrote:
WinSCP should be able to transfer and synchronize files with unicode names even though they may not display correctly.


Similar problem here.

I'm accessing the server (sftp) from two Windows computers. Some folders have unicode names. WinSCP is the same (portable, version 4.1.9 b416).

One OS is localized, everything works fine. The other OS is in English, with Default input language and keyboard set to my locale. Here, for unicode named folders I get "No such file or directory.; Error code: 2; Error message from server: No such file; Request code: 16".
Other folders work fine.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
popins wrote:
One OS is localized, everything works fine. The other OS is in English, with Default input language and keyboard set to my locale. Here, for unicode named folders I get "No such file or directory.; Error code: 2; Error message from server: No such file; Request code: 16".
Other folders work fine.

Please read FAQ, particularly the Remark section. If that does not help, come back.
_________________
Martin Prikryl
nhk
[View user's profile]

Joined: 2010-05-03
Posts: 1
Hi, I have a similar problem. I am trying to transfer files from Ubuntu server to Windows 7 (Korean locale). I turned on the option to force WinSCP to use UTF-8. After I made this change, I could transfer files named in Korean. However non-Korean unicode file names still gives me the msg "could not open remote file".
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
nhk wrote:
Hi, I have a similar problem. I am trying to transfer files from Ubuntu server to Windows 7 (Korean locale). I turned on the option to force WinSCP to use UTF-8. After I made this change, I could transfer files named in Korean. However non-Korean unicode file names still gives me the msg "could not open remote file".

That's expected behaviour. It is explained in the FAQ.
_________________
Martin Prikryl
Guest




prikryl wrote:
nhk wrote:
Hi, I have a similar problem. I am trying to transfer files from Ubuntu server to Windows 7 (Korean locale). I turned on the option to force WinSCP to use UTF-8. After I made this change, I could transfer files named in Korean. However non-Korean unicode file names still gives me the msg "could not open remote file".

That's expected behaviour. It is explained in the FAQ.


According to the FAQ this is true for *displaying* file names but is there really no way to copy all files with unicode names?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
Anonymous wrote:
According to the FAQ this is true for *displaying* file names but is there really no way to copy all files with unicode names?

In some cases it won't work.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License