Debian Chinese settings

Source: Internet
Author: User
Tags locale setting
If we select the English language environment when installing the debian basic system and want to change it to Chinese, we need to complete the following work. Set locale if the locale tool is not installed, first install it, and then run # dpkg-reconfigurelocales to select the language pack. You need to add several options starting with zh_CN

If we select the English language environment when installing the debian basic system and want to change it to Chinese, we need to complete the following work.

Set locale

If the locale tool is not installed, install it first and then run

# Dpkg-reconfigure locales

Select a language pack. You need to add several options starting with zh_CN. you can also add only one option, and then select one of them as the default option. After setting, run the locale command to check whether the current locale setting is Chinese.

Install Chinese fonts

The Chinese environment certainly requires support for Chinese fonts. manually add Chinese xft fonts. we have already mentioned in another article. In addition, we can also use apt to install several free Chinese fonts. For example:

# Apt-get install ttf-arphic-gbsn00lp

# Apt-get install ttf-arphic-gkai00mp

Restart X

If we restart X and find that the entire system interface is still displayed in English, and use the locale command to check that the locale settings of the system have been correctly configured as Chinese. I encountered the problem that some application titles were displayed in Chinese, but the tool menus and file managers were displayed in English. This is probably because the environment variables in the/etc/enviroment file are set incorrectly. Open the/etc/enviroment file and usually find the following two fields:

LANGUAGE = "en_US: en"

LANG = "zh_CN"

Add Chinese characters in the LANGUAGE field, for example:

LANGUAGE = "zh_CN: zh: en_US: en"

Restart X to change the language environment of the system to Chinese.

Main steps:

# Reconfigure locales

1. dpkg-reconfigure locales

2. select a language in the dialog box.

3. less/etc/environment

Change to the following lines:

LC_ALL = "zh_CN.UTF-8"
LANG = "zh_CN.UTF-8"
LANGUAGE = "zh_CN.UTF-8: zh: en_US: en"

Restart your computer

Locale charmap

Output: UTF-8

"OK"

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.