Last Friday-business colleagues feedback customer use our FTP service, found that the files and directories are Chinese all garbled, inconvenient to see the modification of the file directory and other operational failures
Cause: VSFTPD cannot handle the conversion of character encodings, Windows uses GBK encoding, and Linux uses ZH_CN. UTF-8 encoding
Workaround:
1. Using an FTP client that can set the encoding
1-1 FLASHFXP Client, select "Site"-"site Manager"-"Site List"-"Quick Connect", select the connection to use, click "Options"-"character encoding"-"UTF-8".
1-2 FileZilla Client, select "Site"-"site Manager"-"Site List"-"Character set", select Force UTF-8
2. Convert server directory file encoding using CONVMV tool
Linux under: Convmv-f gbk-t UTF-8--notest-r Tools # Tools directory All files garbled conversion, solve Linux under View Windows upload file Chinese garbled fault
Windows under the client using Method 1 inside the tool line VSFTPD server will not be garbled.
3. Modify the server system default file encoding:
vim/etc/sysconfig/i18n
Lang= "ZH_CN. GBK "# GBK is the Windows Chinese encoding format
Export LANG=ZH_CN. GBK #前提是已经生成了GBK的locale
5, in exchange for the ability to handle the character encoding of the FTP server, such as Pureftp
This article is from the "Boyhack" blog, make sure to keep this source http://461205160.blog.51cto.com/274918/1729465
Troubleshoot problems with Windows Client Access VSFTPD Server language garbled