Failed to set locale, defaulting to C

chronos

Active Member
Apr 11, 2009
55
2
28
UTF-8 locales not work properly on Fedora 12.
Templates:
http://download.openvz.org/contrib/template/precreated/fedora-12-i386-default-20091116.tar.gz
http://download.openvz.org/contrib/template/precreated/fedora-12-x86_64-default-20091116.tar.gz

Behaviour:

Code:
[root@server ~]$ yum update
Failed to set locale, defaulting to C
...
Code:
[root@server ~]$ locale  
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: LC_ALL nelze nastavit na implicitn? n?rodn? prost?ed?: Adres?? nebo soubor neexistuje
LANG=cs_CZ.UTF-8
LC_CTYPE="cs_CZ.UTF-8"
LC_NUMERIC="cs_CZ.UTF-8"
LC_TIME="cs_CZ.UTF-8"
LC_COLLATE="cs_CZ.UTF-8"
LC_MONETARY="cs_CZ.UTF-8"
LC_MESSAGES="cs_CZ.UTF-8"
LC_PAPER="cs_CZ.UTF-8"
LC_NAME="cs_CZ.UTF-8"
LC_ADDRESS="cs_CZ.UTF-8"
LC_TELEPHONE="cs_CZ.UTF-8"
LC_MEASUREMENT="cs_CZ.UTF-8"
LC_IDENTIFICATION="cs_CZ.UTF-8"
LC_ALL=
Code:
[root@server ~]$ set LC_CTYPE=cs_CZ.UTF-8
[root@server ~]$ export LC_CTYPE
-bash: warning: setlocale: LC_CTYPE: cannot change locale (cs_CZ.UTF-8)
Solution:
Compile needed locale manually.

Code:
localedef -i cs_CZ -f UTF-8 cs_CZ
Change cs_CZ to your locale.

Additional discussion http://forum.openvz.org/index.php?t=msg&goto=15549&&srch=LC_CTYPE
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!