The perfect solution for the terminal garbled in Linux operating system _linux

Source: Internet
Author: User
Tags ssh

First into the Linux program staff, often get garbled greetings. "Toss". Because of garbled, and finally gave up Linux is not a minority. OK, go to the matter, first see how all kinds of garbled is formed.

Chinese character garbled

This situation is generally installed in Chinese language control, but not the use of Chinese-language applications caused. Only need to start the appropriate software, such as Zhcon. Alternatively, the appropriate software is enabled, but the character set is incorrect, and the corresponding character set, such as export LANG=ZH_CN, is required. UTF-8

Oracle Installation Interface garbled

Although Oracle support multi-language, will automatically choose the character set according to environment variables, but the Chinese installation seems to have problems, but after 10.2 version does not seem to have the problem, the specific can execute the command export Lang=en_us to set the English character set for the environment

English characters garbled

Generally this character garbled more than now cat binary file, because the binary file more control code, will lead to the terminal interface garbled, usually the solution is reset with the end of the command to solve the problem

Other pseudo terminal garbled

Sometimes through SSH into a remote Linux server, cat a core file, and the Reset command can not succeed, how to do? Very simply, look at the following experiment, first cat a python compiled file

Oracle@linux-suse:~> cat fibo.pycm? {Shen c@sdzdzds (ccs:d}}x ' | | jo| g| | |}} Qwds (Nii (TATBTN) (RRR (tfibo.pytfibsccsig}d}}x0| | Jo "|i| | | |}}" qw| S (Nii (Tresultrrrtappend (rrrr) (Rtfib2 SN (RR (Rt?s oracle@linux-suse:~> Not foundoracle@linux-suse:~>

In the SSH terminal to see the garbled, prompt are disorderly, you can use the following command to restore

Oracle@linux-suse:~> Tput Sgr0

Garbled problem is caused by the problem of SSH, because in other terminals, cat with a sample file, will not produce garbled, so the test garbled reason

Oracle@linux-suse:~> ^n

As long as the use of ctrl+v,ctrl+n on the screen garbled, of course, after the recovery test

Oracle@linux-suse:~> echo-e ' XE '

Screen again garbled, OK, and then restore

oracle@linux-suse:~> echo-e ' XF '

Above is the need to blind, because the screen is garbled, the final problem arises because of the hexadecimal character e generated, the solution is also very simple, hexadecimal character f can be.

Above is a small series for everyone on the Linux operating system terminal garbled perfect solution to all content, I hope that we support cloud Habitat Community ~

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.