Home  >  Article  >  Operation and Maintenance  >  Garbled characters appear when ssh accesses linux

Garbled characters appear when ssh accesses linux

王林
王林Original
2020-02-14 16:06:543184browse

Garbled characters appear when ssh accesses linux

The specific method is as follows:

1. Use the ls -a command to find the .bash_profile configuration file;

2. Use the vi editor to open the file , add the following configuration:

LANG=zh_CN.GB2312
export LANG

to display Chinese normally.

(Related learning video sharing: linux video tutorial)

After changing the .bash_profile configuration file, the content of the file is as follows:

# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin
LANG=zh_CN.GB2312
export PATH
export LANG
unset USERNAME

Related article tutorials Recommended: linux tutorial

The above is the detailed content of Garbled characters appear when ssh accesses linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:Linux cannot upload filesNext article:Linux cannot upload files