特殊:Badtitle/NS100:UbuntuLTSP/LTSPLanguageSettings
文章出处: |
{{#if: | {{{2}}} | https://help.ubuntu.com/community/UbuntuLTSP/LTSPLanguageSettings }} |
点击翻译: |
English {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/af | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Afrikaans| [[::UbuntuLTSP/LTSPLanguageSettings/af|Afrikaans]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ar | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|العربية| [[::UbuntuLTSP/LTSPLanguageSettings/ar|العربية]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/az | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|azərbaycanca| [[::UbuntuLTSP/LTSPLanguageSettings/az|azərbaycanca]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/bcc | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|جهلسری بلوچی| [[::UbuntuLTSP/LTSPLanguageSettings/bcc|جهلسری بلوچی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/bg | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|български| [[::UbuntuLTSP/LTSPLanguageSettings/bg|български]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/br | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|brezhoneg| [[::UbuntuLTSP/LTSPLanguageSettings/br|brezhoneg]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ca | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|català| [[::UbuntuLTSP/LTSPLanguageSettings/ca|català]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/cs | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|čeština| [[::UbuntuLTSP/LTSPLanguageSettings/cs|čeština]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/de | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Deutsch| [[::UbuntuLTSP/LTSPLanguageSettings/de|Deutsch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/el | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Ελληνικά| [[::UbuntuLTSP/LTSPLanguageSettings/el|Ελληνικά]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/es | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|español| [[::UbuntuLTSP/LTSPLanguageSettings/es|español]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/fa | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|فارسی| [[::UbuntuLTSP/LTSPLanguageSettings/fa|فارسی]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/fi | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|suomi| [[::UbuntuLTSP/LTSPLanguageSettings/fi|suomi]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/fr | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|français| [[::UbuntuLTSP/LTSPLanguageSettings/fr|français]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/gu | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|ગુજરાતી| [[::UbuntuLTSP/LTSPLanguageSettings/gu|ગુજરાતી]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/he | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|עברית| [[::UbuntuLTSP/LTSPLanguageSettings/he|עברית]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/hu | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|magyar| [[::UbuntuLTSP/LTSPLanguageSettings/hu|magyar]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/id | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Bahasa Indonesia| [[::UbuntuLTSP/LTSPLanguageSettings/id|Bahasa Indonesia]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/it | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|italiano| [[::UbuntuLTSP/LTSPLanguageSettings/it|italiano]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ja | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|日本語| [[::UbuntuLTSP/LTSPLanguageSettings/ja|日本語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ko | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|한국어| [[::UbuntuLTSP/LTSPLanguageSettings/ko|한국어]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ksh | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Ripoarisch| [[::UbuntuLTSP/LTSPLanguageSettings/ksh|Ripoarisch]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/mr | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|मराठी| [[::UbuntuLTSP/LTSPLanguageSettings/mr|मराठी]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ms | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Bahasa Melayu| [[::UbuntuLTSP/LTSPLanguageSettings/ms|Bahasa Melayu]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/nl | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Nederlands| [[::UbuntuLTSP/LTSPLanguageSettings/nl|Nederlands]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/no | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|norsk| [[::UbuntuLTSP/LTSPLanguageSettings/no|norsk]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/oc | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|occitan| [[::UbuntuLTSP/LTSPLanguageSettings/oc|occitan]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/pl | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|polski| [[::UbuntuLTSP/LTSPLanguageSettings/pl|polski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/pt | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|português| [[::UbuntuLTSP/LTSPLanguageSettings/pt|português]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ro | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|română| [[::UbuntuLTSP/LTSPLanguageSettings/ro|română]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/ru | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|русский| [[::UbuntuLTSP/LTSPLanguageSettings/ru|русский]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/si | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|සිංහල| [[::UbuntuLTSP/LTSPLanguageSettings/si|සිංහල]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/sq | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|shqip| [[::UbuntuLTSP/LTSPLanguageSettings/sq|shqip]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/sr | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|српски / srpski| [[::UbuntuLTSP/LTSPLanguageSettings/sr|српски / srpski]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/sv | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|svenska| [[::UbuntuLTSP/LTSPLanguageSettings/sv|svenska]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/th | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|ไทย| [[::UbuntuLTSP/LTSPLanguageSettings/th|ไทย]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/tr | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Türkçe| [[::UbuntuLTSP/LTSPLanguageSettings/tr|Türkçe]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/vi | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|Tiếng Việt| [[::UbuntuLTSP/LTSPLanguageSettings/vi|Tiếng Việt]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/yue | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|粵語| [[::UbuntuLTSP/LTSPLanguageSettings/yue|粵語]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/zh | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|中文| [[::UbuntuLTSP/LTSPLanguageSettings/zh|中文]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/zh-hans | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|中文(简体)| [[::UbuntuLTSP/LTSPLanguageSettings/zh-hans|中文(简体)]]}}|}} {{#ifexist: {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings | {{#if: | :}}UbuntuLTSP/LTSPLanguageSettings}}/zh-hant | • {{#if: UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|中文(繁體)| [[::UbuntuLTSP/LTSPLanguageSettings/zh-hant|中文(繁體)]]}}|}} |
{{#ifeq:UbuntuHelp:UbuntuLTSP/LTSPLanguageSettings|:UbuntuLTSP/LTSPLanguageSettings|请不要直接编辑翻译本页,本页将定期与来源同步。}} |
{{#ifexist: :UbuntuLTSP/LTSPLanguageSettings/zh | | {{#ifexist: UbuntuLTSP/LTSPLanguageSettings/zh | | {{#ifeq: {{#titleparts:UbuntuLTSP/LTSPLanguageSettings|1|-1|}} | zh | | }} }} }} {{#ifeq: {{#titleparts:UbuntuLTSP/LTSPLanguageSettings|1|-1|}} | zh | | }}
Gnome language
New languages can be installed with a graphical tool in System->Administration. It's possible to select the default (login) language for new users using this same tool.
LDM language
LTSP logins don't use GDM (Gnome Display Manager) at all. Instead LDM (Local Display Manager) is used. LDM's language settings are defined in /var/lib/tftpboot/ltsp/i386/lts.conf. LDM language affects the language of the users' X (Gnome) session. It's possible to define a different language for each thin client as seen below:
[default] LDM_DIRECTX=True LOCALDEV=True LDM_LANGUAGE="fi_FI.UTF-8" [44:4d:50:e2:11:7f] LDM_DIRECTX=True LOCALDEV=True LDM_LANGUAGE="en_US.UTF-8"
Defining a locale here affects all locale-specific aspects of the X session. For example if en_US.UTF-8 is used, default paper format in OpenOffice will be letter instead of A4.
System files
The system-wide language settings are stored in the file /etc/default/locale. This file is parsed by various init.d scripts. The file /etc/environment contains similar settings.
OpenSSH language settings
OpenSSH does not have any language settings of it's own, but sometimes it's settings affect the user's effective locale settings. We'll use Ubuntu's SSH configuration as an example:
# /etc/ssh/sshd_config AcceptEnv LANG LC_* # /etc/ssh/ssh_config SendEnv LANG LC_*
This means that by default Ubuntu SSH server accepts the LANG and LC_* environment variables from the SSH client. Ubuntu's SSH client also sends those variables to sshd by default. This has an effect only if bash or something else does not set the same variables. It's possible to run into trouble in following circumstances:
- SSH server accepts the LANG and LC_* from the SSH client
- SSH client does not pass the variables mentioned above
- Bash does not set any language variables
In this case the language variables are not inherited from system defaults, but default to POSIX instead. This can be fixed by defining the language variables in Bash configuration (see below).
Bash-shell
Bash language settings override those sent by the SSH client (see SendEnv) above.
- /etc/profile: system-wide Bash login shell settings
- /etc/bash.bashrc: system-wide Bash shell settings (not for login shells)
- $HOME/.bash_profile: per-user Bash login shell settings
- $HOME/.bashrc: per-user Bash shell settings (not for login shells)
Regardless of the file you edit you need to add something like this it:
export LC_ALL=fi_FI.UTF-8 export LANG=fi_FI.UTF-8
This will take care of language settings in local shell logins and logins via SSH.