[Bug 2091657] Re: systemd-localed requires read-only-etc hacks for /etc/vconsole.conf and /etc/locale.conf

Philip Meulengracht 2091657 at bugs.launchpad.net
Thu Jan 30 08:49:56 UTC 2025


Hey!

So tested with a new UC 24 system that includes the systemd from enr0n
ppa and has the following setup

$ systemctl --version
systemd 255 (255.4-1ubuntu8.6~ppa3)
+PAM +AUDIT +SELINUX +APPARMOR +IMA +SMACK +SECCOMP +GCRYPT -GNUTLS +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD +LIBCRYPTSETUP +LIBFDISK +PCRE2 -PWQUALITY +P11KIT +QRENCODE +TPM2 +BZIP2 +LZ4 +XZ +ZLIB +ZSTD -BPF_FRAMEWORK -XKBCOMMON +UTMP +SYSVINIT default-hierarchy=unified

$ ls -l /etc/locale*
lrwxrwxrwx 1 root root 20 Jan 29 14:48 /etc/locale.conf -> writable/locale.conf

$ ls -l /etc/default/locale
lrwxrwxrwx 1 root root 23 Jan 30 08:28 /etc/default/locale -> ../writable/locale.conf

$ cat /etc/locale.conf
LANG=C.UTF-8

1) "localectl status"

$ localectl status
System Locale: LANG=C.UTF-8
    VC Keymap: (unset)     
   X11 Layout: (unset)

2) localectl set-locale LANG=en_AU.UTF-8

$ sudo localectl set-locale LANG=en_AU.UTF-8
Failed to issue method call: Failed to set locale: Device or resource busy

And just for info trying to set the currently set does not produce an
error, assuming this means that the symlinks are setup correctly

$ sudo localectl set-locale LANG=C.UTF-8

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/2091657

Title:
  systemd-localed requires read-only-etc hacks for /etc/vconsole.conf
  and /etc/locale.conf

Status in systemd package in Ubuntu:
  Invalid
Status in systemd source package in Noble:
  Triaged

Bug description:
  [Impact]

  Ubuntu Core has a read-only /etc, but a writable partition in
  /etc/writable. In some versions of Ubuntu, the systemd package ships a
  patch to follow symlinks from /etc/ -> /etc/writable, e.g. for files
  like /etc/locale.conf.

  In Core24, this patch needs to be expanded for /etc/locale.conf and
  /etc/vconsole.conf in systemd-localed.

  [Test Plan]

  TODO

  [Where problems could occur]

  This hack is designed to be a no-op in non-Ubuntu Core cases. I.e.,
  when /etc/writable does not exist or does not have a link for the
  given path in etc, the original path is used.

  As is evident by the ever-expanding nature of this patch, this is not
  a complete solution. It's possible that more cases will be found where
  this hack needs to be applied.

  [Other information]

  This patch is not carried in supported releases newer than Noble.
  While this patch is far from ideal, expanding this hack has become the
  go-to for existing stable releases.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/2091657/+subscriptions




More information about the foundations-bugs mailing list