LXC container CentOS7: localectl connection timeout

olsonn

Active Member
Oct 25, 2017
11
0
41
50
LXC container CentOS7: localectl connection timeout

locale shows:

LANG=
LC_CTYPE="POSIX"
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=

as localectl does not work
how to set it as utf-8
 
Confirm this. On Centos 7 lxc container locale service doesn't work.
Localectl command report time out error
some part of messages error log:

Dec 19 16:48:04 mysql-dev dbus[54]: [system] Activating via systemd: service name='org.freedesktop.locale1' unit='dbus-org.freedesktop.locale1.service'
Dec 19 16:48:04 mysql-dev dbus-daemon: dbus[54]: [system] Activating via systemd: service name='org.freedesktop.locale1' unit='dbus-org.freedesktop.locale1.service'
Dec 19 16:48:04 mysql-dev systemd: Starting Locale Service...
Dec 19 16:48:04 mysql-dev systemd: Failed at step NETWORK spawning /usr/lib/systemd/systemd-localed: Permission denied
Dec 19 16:48:04 mysql-dev systemd: systemd-localed.service: main process exited, code=exited, status=225/NETWORK
Dec 19 16:48:04 mysql-dev systemd: Failed to start Locale Service.
Dec 19 16:48:04 mysql-dev systemd: Unit systemd-localed.service entered failed state.
Dec 19 16:48:04 mysql-dev systemd: systemd-localed.service failed.
Dec 19 16:48:29 mysql-dev dbus[54]: [system] Failed to activate service 'org.freedesktop.locale1': timed out
Dec 19 16:48:29 mysql-dev dbus-daemon: dbus[54]: [system] Failed to activate service 'org.freedesktop.locale1': timed out
 
I'm trying to run SABnzbd inside a CentOS7 LXC and hitting this problem. Thought I had it sorted by adding the following:
Code:
echo "export LANG=en_US.UTF-8" >> /etc/profile.d/locale.sh
echo "export LANGUAGE=en_US.UTF-8" >> /etc/profile.d/locale.sh
source /etc/profile.d/locale.sh

Now when I do a
Code:
locale
it comes up as UTF-8 but SABnzbd still fails as the preferred encoding is still ANSI_X3.4-1968 for some reason.
 

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!