Locale weirdness after latest upgrade (was Re: cannot log on as root after upgrade)

From: Conrad J. Sabatier <conrads_at_cox.net>
Date: Wed, 20 Apr 2005 18:03:23 -0500
On Tue, 19 Apr 2005 20:03:41 -0500, Eric Anderson
<anderson_at_centtech.com> wrote:

> Li, Qing wrote:
> > 	I performed a cvs sync today and buildworld. After the system
> > reboot
> >       I cannot log on as root, the error message that is shown on
> > console
> >       is "login: pam_acct_mgmt(): authentication error".
> >       I can still log on as a normal user.
> > 
> >       What do I need to do to fix this? Did I screw something up
> >       during mergemaster ?
> 
> Sounds like it - can you boot into single user mode and check out your
> passwd file?

I suspect he may be encountering the same problem I'm seeing here after
my latest upgrade today, namely, locale weirdness.

If I set any locale-related environment variables (LANG, LC_ALL, or
whatever) in my .bashrc, I can't login.  Bash just core dumps
immediately (even after rebuilding bash).  I had the same problem with
kdm.  I had to change the LANG=en_US default setting in kdmrc to
LANG=C.  Setting it to null also produced the same behavior, by the way.

I discovered the problem by running gdb on the core dumps I was getting
from bash and kdm_greet.  Here's the head of a backtrace from bash:

#0  strcpy () at /usr/src/lib/libc/amd64/string/strcpy.S:52
#1  0x0000000800be2413 in __collate_load_tables (
    encoding=0x800d41a80 "en_US.ISO8859-1")
    at /usr/src/lib/libc/locale/collate.c:86
#2  0x0000000800bb59d8 in loadlocale (category=1)
    at /usr/src/lib/libc/locale/setlocale.c:283
#3  0x0000000800bb5741 in setlocale (category=0, 
    locale=0x5a2580 "en_US.ISO8859-1")
    at /usr/src/lib/libc/locale/setlocale.c:198

(the rest has no symbols)

This is very strange.

-- 
Conrad J. Sabatier <conrads_at_cox.net> -- "In Unix veritas"
Received on Wed Apr 20 2005 - 21:03:33 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:32 UTC