OS-5182: systemd-localed.service fails to run in CentOS 7 lx-brand

Details

Issue Type:Bug
Priority:4 - Normal
Status:Open
Created at:2016-02-23T15:00:23.000Z
Updated at:2019-08-28T17:19:10.173Z

People

Created by:Former user
Reported by:Former user

Labels

lxbrand

Description

Doing some testing I hit an issue where you can't set the locale in a CentOS 7 lx-brand instance:

# localectl set-locale LANG="en_US.UTF-8"
Failed to issue method call: Connection timed out

Checking the system, the relevant systemd-localed.service service failed to start:

[root@3d2e7d9d-438c-48f2-aaec-483310c5dbd8 ~]# systemctl status systemd-localed.service 
● systemd-localed.service - Locale Service
   Loaded: loaded (/usr/lib/systemd/system/systemd-localed.service; static; vendor preset: disabled)
   Active: failed (Result: exit-code) since Tue 2016-02-23 14:27:14 UTC; 3min 12s ago
     Docs: man:systemd-localed.service(8)
           man:locale.conf(5)
           man:vconsole.conf(5)
           http://www.freedesktop.org/wiki/Software/systemd/localed
  Process: 51507 ExecStart=/usr/lib/systemd/systemd-localed (code=exited, status=225/NETWORK)
 Main PID: 51507 (code=exited, status=225/NETWORK)

Tried to start it:

[root@3d2e7d9d-438c-48f2-aaec-483310c5dbd8 ~]# systemctl start systemd-localed.service 
Job for systemd-localed.service failed because the control process exited with error code. See "systemctl status systemd-localed.service" and "journalctl -xe" for details.

From journalctl -xe:

-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit systemd-localed.service has begun starting up.
Feb 23 14:32:30 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 systemd[55693]: Failed at step NETWORK spawning /usr/lib/systemd/systemd-lo
-- Subject: Process /usr/lib/systemd/systemd-localed could not be executed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- The process /usr/lib/systemd/systemd-localed could not be executed and failed.
-- 
-- The error number returned by this process is 90.
Feb 23 14:32:30 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 systemd[34914]: systemd-localed.service: main process exited, code=exited, 
Feb 23 14:32:30 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 systemd[34914]: Failed to start Locale Service.
-- Subject: Unit systemd-localed.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit systemd-localed.service has failed.
-- 
-- The result is failed.
Feb 23 14:32:30 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 systemd[34914]: Unit systemd-localed.service entered failed state.
Feb 23 14:32:30 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 systemd[34914]: systemd-localed.service failed.

Relevant PI:

# /native/sbin/uname -a
SunOS 3d2e7d9d-438c-48f2-aaec-483310c5dbd8 5.11 joyent_20160204T173314Z i86pc i386 i86pc

Comments

Comment by Former user
Created at 2016-02-25T03:06:23.000Z

There are a number of terrible things going on here.
Of the many options set on the localed service, one of the most problematic is PrivateNetwork=Yes. That causes the service to attempt to place itself in a network namespace. Worse yet, the means by which it communicates that fact is by sending a zero-length message through an AF_UNIX socket. Our emulation balks at sendmsg/recvmsg when no iovec is specified. Looking at emulation in the lower levels, such a transaction may not be allowed at all.

One means of fixing this might be to alter those configuration options, but they would likely be replaced if the systemd package was updated by the user.