This isSSH Secure Shell ClientIf the problem persists for many years, both the client and server are required.'Utf-8'Encoding,WindowsThe Chinese version is not encodedUTF-8. Zh_CN.UTF-8 is the Chinese language environment of UTF Encoding.
WindowsYesGb2312Encoding, mostLinuxThe system supportsUTF-8The local code is used for remote login, so garbled characters may occur.Solutions:
Solution 1: Modify the environment variables of a Linux Server
In Linux, There Is A. bash_profile configuration file under the root directory of the user. This configuration is only valid for the current user. If it is valid for all users, modify the/etc/profile file
Use the LS-a command to view the file. Use the VI editor to open the file and add
Lang = zh_cn.gb2312export Lang. After you change the. bash_profile configuration file, the file content is as follows: #. bash_profile # Get the aliases and functionsif [-f ~ /. Bashrc]; then .~ /. Bashrcfi # user specific environment and startup programspath = $ path: $ home/binlang = zh_cn.gb2312export path
Export Lang
Unset Username
Solution 2: or use other remote login software,Modify the character encodingUTF-8.
PS: remote login to the software command line interface putty, cterm, securecrt, including filezilla, Secure Shell client, and xming, xshell, and xmanager.
The following uses putty and securecrt as examples.
Modify securecrt settings: Options-> session options-> appearance-> character (character), select UTF-8.
PuttySelect windows -- translation on the left of the Configuration window, and select UTF-8 from the sorted ed data assumed to be in which character set drop-down list on the right"