Locale not supported by C library.

Everytime I start nvidia-settings I get this error:

(process:2146): Gtk-WARNING **: 19:07:29.062: Locale not supported by C library.
        Using the fallback 'C' locale.

And another one that I have no idea how to get rid of or suppress at least:

(nvidia-settings:2146): GLib-GObject-CRITICAL **: 19:07:29.157: g_object_unref: assertion 'G_IS_OBJECT (object)' failed

However, I've been trying to get rid of the locale error for some time since it was the easiest to find threads on it. I've done everything in the System Locale section of this post: Localize Manjaro
However, nothing has changed.

Output of locale:

locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=en_GB.UTF-8
LC_CTYPE="en_GB.UTF-8"
LC_NUMERIC=en_GB.UTF-8
LC_TIME=en_GB.UTF-8
LC_COLLATE="en_GB.UTF-8"
LC_MONETARY=en_DE.UTF-8
LC_MESSAGES="en_GB.UTF-8"
LC_PAPER=ro_RO.UTF-8
LC_NAME=ro_RO.UTF-8
LC_ADDRESS=ro_RO.UTF-8
LC_TELEPHONE=ro_RO.UTF-8
LC_MEASUREMENT=en_DE.UTF-8
LC_IDENTIFICATION=ro_RO.UTF-8
LC_ALL=

Output of locale -a:

locale -a
C
en_GB.utf8
en_US.utf8
POSIX
ro_RO.utf8

I've even generated the locales again.

sudo locale-gen

And then set the system locale as in that post:

sudo localectl set-locale LANG=en_GB.UTF-8

I don't know what else to do.

Hello,
Eventually provide also:
localectl list-locales

Maybe you need to kate /etc/locale.gen and then uncomment
en_GB.UTF-8 UTF-8
en_US.UTF-8 UTF-8
ro_RO.UTF-8 UTF-8

Also look down the last lines to see the Locales enabled by Calamares, so there are no duplicates in the file.

Then you run:
sudo locale-gen
Hope this helps.

1 Like
localectl list-locales
en_GB.UTF-8
en_US.UTF-8
ro_RO.UTF-8
# Locales enabled by Calamares
en_US.UTF-8 UTF-8
en_GB.UTF-8 UTF-8
ro_RO.UTF-8 UTF-8

That looks in order AFAIK. I wonder if cat /etc/locale.conf will reveal something else than locale. Maybe edit it manually and make it like:

LANG=en_GB.UTF-8
LC_ADDRESS=ro_RO.UTF-8
LC_IDENTIFICATION=ro_RO.UTF-8
LC_MEASUREMENT=ro_RO.UTF-8
LC_MONETARY=ro_RO.UTF-8
LC_NAME=ro_RO.UTF-8
LC_NUMERIC=ro_RO.UTF-8
LC_PAPER=ro_RO.UTF-8
LC_TELEPHONE=ro_RO.UTF-8
LC_TIME=ro_RO.UTF-8
1 Like

cat /etc/local.conf:

LANG=en_GB.UTF-8
LC_NUMERIC=ro_RO.UTF-8
LC_TIME=ro_RO.UTF-8
LC_MONETARY=ro_RO.UTF-8
LC_PAPER=ro_RO.UTF-8
LC_NAME=ro_RO.UTF-8
LC_ADDRESS=ro_RO.UTF-8
LC_TELEPHONE=ro_RO.UTF-8
LC_MEASUREMENT=ro_RO.UTF-8
LC_IDENTIFICATION=ro_RO.UTF-8

That seems in order too. No idea. Is the only app that gives you that error? What version of nvidia drivers you have installed?

1 Like

Any GTK app gives me that error.

440

My last question, when you run:localectl from terminal, do you get this:

   System Locale: LANG=en_GB.UTF-8
                  LC_NUMERIC=ro_RO.UTF-8
                  LC_TIME=ro_RO.UTF-8
                  LC_MONETARY=ro_RO.UTF-8
                  LC_PAPER=ro_RO.UTF-8
                  LC_NAME=ro_RO.UTF-8
                  LC_ADDRESS=ro_RO.UTF-8
                  LC_TELEPHONE=ro_RO.UTF-8
                  LC_MEASUREMENT=ro_RO.UTF-8
                  LC_IDENTIFICATION=ro_RO.UTF-8
       VC Keymap: uk
      X11 Layout: gb
       X11 Model: pc105

or something alike ?

1 Like
localectl
   System Locale: LANG=en_GB.UTF-8
                  LC_NUMERIC=ro_RO.UTF-8
                  LC_TIME=ro_RO.UTF-8
                  LC_MONETARY=ro_RO.UTF-8
                  LC_PAPER=ro_RO.UTF-8
                  LC_NAME=ro_RO.UTF-8
                  LC_ADDRESS=ro_RO.UTF-8
                  LC_TELEPHONE=ro_RO.UTF-8
                  LC_MEASUREMENT=ro_RO.UTF-8
                  LC_IDENTIFICATION=ro_RO.UTF-8
       VC Keymap: us
      X11 Layout: us
       X11 Model: pc105

It seems it's a gtk issue, not system, so no need to look for proper system setup.
Look into gtk related configuration.

Is it possible you have installed an AUR app that did this?

Check with a new user, to narrow down if it system wide or user config.

Check gtk settings for locale related settings (using dConf or other?).

Test starting nvidia settings from terminal, prepending with

LC_COLLATE=C
LC_CTYPE=C

One at a time, or both.

I would not even ask for system up-to-date :stuck_out_tongue:

2 Likes

I've discovered that tlp throws a locale error too:

tlp
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LANGUAGE = "",
        LC_ALL = (unset),
        LC_ADDRESS = "ro_RO.UTF-8",
        LC_NAME = "ro_RO.UTF-8",
        LC_MONETARY = "en_DE.UTF-8",
        LC_PAPER = "ro_RO.UTF-8",
        LC_IDENTIFICATION = "ro_RO.UTF-8",
        LC_TELEPHONE = "ro_RO.UTF-8",
        LC_MEASUREMENT = "en_DE.UTF-8",
        LC_TIME = "en_GB.UTF-8",
        LC_NUMERIC = "en_GB.UTF-8",
        LANG = "en_GB.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_GB.UTF-8").
Usage: tlp start|true|bat|false|ac|usb|bayoff|chargeonce|discharge|setcharge|fullcharge|recalibrate|diskid

On a new user, it seems that I don't get this error.

How would I go about doing that?

That's not a valid locale found in /etc/locale.gen.

2 Likes

No way that solved it. Thank you at last!

I'm jealous on your eye sight. Even with my glasses on i did not spot that, reason why i shared mine :smiley:

You couldn't have because it seems to be a recent change.
It wasn't present in any of the posts before your answering :man_shrugging:


edit: see posts below :laughing:

What do you mean it wasn't present before? Look here ^^

1 Like

Hah, so much for my eyesight (and browser search) :laughing:

1 Like

What exactly was your repair action?

I mean, /etc/locale.conf looked proper.
The wrong locale was only found by some commands (tlp, etc).
From the above, I assume some local setting was the issue.

Some answer may help understand (what we can't see before our eyes... :wink:

I changed the language for LC_MEASUREMENT and LC_MONETARY to a valid locale.
In KDE I just went to Formats - System Settings Module and changed the offending language.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.

Forum kindly sponsored by