Bug 1242691 - Broken locale with %_install_langs en_US.utf8
Summary: Broken locale with %_install_langs en_US.utf8
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: glibc
Version: 22
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Carlos O'Donell
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-07-14 00:18 UTC by Loïc Yhuel
Modified: 2016-11-24 12:05 UTC (History)
11 users (show)

Fixed In Version: glibc-2.21-8.fc22
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-01-20 09:55:30 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Loïc Yhuel 2015-07-14 00:18:29 UTC
Description of problem:
With "%_install_langs en_US.utf8" in /etc/rpm/macros.lang, locale is broken after glibc update.
~ ls -lh /usr/lib/locale/locale-archive 
-rw-r--r-- 1 root root 102K Jul 14 01:32 /usr/lib/locale/locale-archive
~ locale -a
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_COLLATE to default locale: No such file or directory
C
POSIX

This is strange since looking at https://bugzilla.redhat.com/show_bug.cgi?id=156477, en_US.utf8 should work.


Version-Release number of selected component (if applicable):
glibc-common-2.21-7.fc22.x86_64


How reproducible:
Set /etc/rpm/macros.lang and reinstall glibc-common

Actual results:
locale -a gives errors, and only lists C and POSIX

Expected results:
locale -a should list C, POSIX, and en_US.utf8


Additional info:
"%_install_langs en_US" works
~ ls -lh /usr/lib/locale/locale-archive 
-rw-r--r-- 1 root root 2.1M Jul 14 02:05 /usr/lib/locale/locale-archive
~ locale -a
C
en_US
en_US.iso88591
en_US.iso885915
en_US.utf8
POSIX

Comment 1 Carlos O'Donell 2015-07-14 02:35:02 UTC
(In reply to Loïc Yhuel from comment #0)
> Description of problem:
> With "%_install_langs en_US.utf8" in /etc/rpm/macros.lang, locale is broken
> after glibc update.
> ~ ls -lh /usr/lib/locale/locale-archive 
> -rw-r--r-- 1 root root 102K Jul 14 01:32 /usr/lib/locale/locale-archive
> ~ locale -a
> locale: Cannot set LC_CTYPE to default locale: No such file or directory
> locale: Cannot set LC_MESSAGES to default locale: No such file or directory
> locale: Cannot set LC_COLLATE to default locale: No such file or directory
> C
> POSIX
> 
> This is strange since looking at
> https://bugzilla.redhat.com/show_bug.cgi?id=156477, en_US.utf8 should work.
> 
> 
> Version-Release number of selected component (if applicable):
> glibc-common-2.21-7.fc22.x86_64
> 
> 
> How reproducible:
> Set /etc/rpm/macros.lang and reinstall glibc-common
> 
> Actual results:
> locale -a gives errors, and only lists C and POSIX
> 
> Expected results:
> locale -a should list C, POSIX, and en_US.utf8

This is certainly odd. Since this is exactly the scenario we tested. I'll have to try this myself and get back to you.

Comment 2 Orion Poplawski 2015-08-27 21:04:33 UTC
I'm seeing this on a relatively fresh rawhide install with:

echo '%_install_langs C:en_US:en_US.UTF-8' > /mnt/sysimage/etc/rpm/macros

but not on my f22 systems.

glibc-2.22.90-3.fc24.x86_64

Comment 3 Orion Poplawski 2015-09-16 15:38:59 UTC
Seeing the same on F23.

# build-local-archive
build-locale-archive: cannot read archive header
# ls -l /usr/lib/locale
total 4
-rw-r--r--. 1 root root 103860 Sep 15 16:13 locale-archive
-rw-r--r--. 1 root root      0 Sep 15 16:13 locale-archive.tmpl
# ls /usr/share/locale
af             de              eu   ja                 ne                 ta
all_languages  el              fa   ka                 nl                 te
ar             en              fi   kf5_all_languages  nn                 tg
as             en@arabic       fr   kk                 or                 th
ast            en@boldquot     fy   km                 pa                 tr
be             en@cyrillic     ga   kn                 pl                 tt
be@latin       en@greek        gl   ko                 ps                 ug
bg             en@hebrew       gu   ku                 pt                 uk
bn             en@piglatin     ha   l10n               pt_BR              uz
bn_IN          en@quot         he   lb                 ro                 uz@cyrillic
br             en@shaw         hi   locale.alias       ru                 vi
bs             en_AU           hne  lt                 se                 wa
ca             en_CA           hr   lv                 si                 xh
ca@valencia    en_GB           hsb  mai                sl                 zh_CN
crh            en_NZ           hu   mk                 sq                 zh_HK
cs             en_US           hy   ml                 sr                 zh_TW
csb            en_US@piglatin  ia   mr                 sr@ijekavian
currency       eo              id   ms                 sr@ijekavianlatin
cy             es              is   nb                 sr@latin
da             et              it   nds                sv
# locale -a
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_COLLATE to default locale: No such file or directory
C
POSIX

glibc-2.22-2.fc23.x86_64

Comment 4 Carlos O'Donell 2015-09-17 16:32:16 UTC
On F23 we've found and fixed bug 1262040, which should be coming soon as an update.

Could you please test the F23 update when it's done building?

http://koji.fedoraproject.org/koji/buildinfo?buildID=685815

Comment 5 Orion Poplawski 2015-09-17 17:36:55 UTC
Yup, that did the trick, thanks:

# locale -a
C
en_US
en_US.iso88591
en_US.iso885915
en_US.utf8
POSIX

Comment 6 Carlos O'Donell 2015-09-17 18:39:05 UTC
(In reply to Orion Poplawski from comment #5)
> Yup, that did the trick, thanks:
> 
> # locale -a
> C
> en_US
> en_US.iso88591
> en_US.iso885915
> en_US.utf8
> POSIX

Awesome, I'm marking this as a duplicate of the other then.

*** This bug has been marked as a duplicate of bug 1262040 ***

Comment 7 Loïc Yhuel 2015-09-17 21:38:05 UTC
For me it didn't fail with en_US, and failed with en_US.utf8, but it's probably just random.
I'm still on f22, so I can't test the updated package.
I will check when I update, hopefully soon.

Comment 8 Orion Poplawski 2015-09-28 20:01:42 UTC
I see this now on a fresh F22 install with glibc-2.21-7.fc22.x86_64 so reopening so it gets fixed there too.

Comment 9 Carlos O'Donell 2015-09-28 20:23:32 UTC
(In reply to Orion Poplawski from comment #8)
> I see this now on a fresh F22 install with glibc-2.21-7.fc22.x86_64 so
> reopening so it gets fixed there too.

Mike,

Would it be possible to get a backport of your F23 fix to F22 for %_install_langs?

Thanks you!

Comment 10 Mike FABIAN 2015-09-29 06:08:15 UTC
Yes, I am doing an update for F22 now.

Comment 11 Mike FABIAN 2015-09-29 14:52:00 UTC
https://bugzilla.redhat.com/show_bug.cgi?id=1262040#c21

glibc-2.21-8.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2015-6eb4b16455

Comment 12 Carlos O'Donell 2015-09-29 14:59:09 UTC
(In reply to Mike FABIAN from comment #11)
> https://bugzilla.redhat.com/show_bug.cgi?id=1262040#c21
> 
> glibc-2.21-8.fc22 has been submitted as an update to Fedora 22.
> https://bodhi.fedoraproject.org/updates/FEDORA-2015-6eb4b16455

Thanks Mike!

Comment 13 Adam Williamson 2015-09-30 22:08:52 UTC
The f23 fix already went stable so I don't believe this needs to be marked as F23Blocker any more, right? Re-propose if I missed something.


Note You need to log in before you can comment on or make changes to this bug.