CentOS 7 LXC Local Issue

liberodark

Member
Apr 26, 2021
105
21
23
31
Hi

Have deploy today CentOS 7 & Template too in LXC.
Im using PVE 7 with last update but have see strange issue when login into CT :

Code:
-bash: warning: setlocale: LC_CTYPE: cannot change locale (C.utf8): No such file or directory
-bash: warning: setlocale: LC_COLLATE: cannot change locale (C.utf8): No such file or directory
-bash: warning: setlocale: LC_MESSAGES: cannot change locale (C.utf8): No such file or directory
-bash: warning: setlocale: LC_NUMERIC: cannot change locale (C.utf8): No such file or directory
-bash: warning: setlocale: LC_TIME: cannot change locale (C.utf8): No such file or directory

This issue do not affect CentOS 8 is only on CentOS 7
I didn't have this problem a little while ago it's strange.

Have make a workaround with set

Code:
LANG=en_US.utf-8
LC_ALL=en_US.utf-8

in
Code:
in /etc/environment

My CT Conf :

Code:
arch: amd64
cores: 1
hostname: test2
memory: 512
net0: name=eth0,bridge=vmbr0,firewall=1,hwaddr=42:7D:6B:37:FC:75,type=veth
ostype: centos
rootfs: netapp_sas:112/vm-112-disk-0.raw,size=8G
swap: 512

PVE Packages :
Code:
proxmox-ve: 7.0-2 (running kernel: 5.11.22-5-pve)
pve-manager: 7.0-13 (running version: 7.0-13/7aa7e488)
pve-kernel-helper: 7.1-2
pve-kernel-5.11: 7.0-8
pve-kernel-5.4: 6.4-5
pve-kernel-5.11.22-5-pve: 5.11.22-10
pve-kernel-5.11.22-4-pve: 5.11.22-9
pve-kernel-5.4.128-1-pve: 5.4.128-1
pve-kernel-5.4.106-1-pve: 5.4.106-1
ceph-fuse: 14.2.21-1
corosync: 3.1.5-pve1
criu: 3.15-1+pve-1
glusterfs-client: 9.2-1
ifupdown: not correctly installed
ifupdown2: 3.1.0-1+pmx3
ksm-control-daemon: 1.4-1
libjs-extjs: 7.0.0-1
libknet1: 1.22-pve1
libproxmox-acme-perl: 1.4.0
libproxmox-backup-qemu0: 1.2.0-1
libpve-access-control: 7.0-5
libpve-apiclient-perl: 3.2-1
libpve-common-perl: 7.0-10
libpve-guest-common-perl: 4.0-2
libpve-http-server-perl: 4.0-3
libpve-storage-perl: 7.0-12
libqb0: 1.0.5-1
libspice-server1: 0.14.3-2.1
lvm2: 2.03.11-2.1
lxc-pve: 4.0.9-4
lxcfs: 4.0.8-pve2
novnc-pve: 1.2.0-3
proxmox-backup-client: 2.0.11-1
proxmox-backup-file-restore: 2.0.11-1
proxmox-mini-journalreader: 1.2-1
proxmox-widget-toolkit: 3.3-6
pve-cluster: 7.0-3
pve-container: 4.1-1
pve-docs: 7.0-5
pve-edk2-firmware: 3.20210831-1
pve-firewall: 4.2-4
pve-firmware: 3.3-2
pve-ha-manager: 3.3-1
pve-i18n: 2.5-1
pve-qemu-kvm: 6.0.0-4
pve-xtermjs: 4.12.0-1
qemu-server: 7.0-16
smartmontools: 7.2-pve2
spiceterm: 3.2-2
vncterm: 1.7-1
zfsutils-linux: 2.0.5-pve1
 
hi,

Im using PVE 7 with last update but have see strange issue when login into CT :
do you see that when you do pct enter 112? or on the web shell?

did you use the centos 7 template from our repository?

does the issue still happen if you remove /etc/locale.conf file? (that one has LANG=C.utf8 defined in it to fix a small issue with systemd-firstboot)
 
Hi,

Sorry for the response time.

With
Code:
pct enter 112
don't have issue but on console from PVE or SSH have the issue.
And if i remove
Code:
/etc/locale.conf
that work too.

Code:
cat /etc/locale.conf
LANG=C.utf8

Should I not save?
Code:
/etc/locale.conf

Best Regards
 
And if i remove
Code:
/etc/locale.conf
that work too.
thanks for checking, i reproduced the error messages here, interestingly it doesn't happen on centos 8. seems like the langpack packages are missing on 7.

you can adapt the /etc/locale.conf to say LANG=C and it should work, you can also set it to en_US.utf-8
 

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!