Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 9 May 2012 10:03:59 -0500 (CDT)
From:      Robert Bonomi <bonomi@mail.r-bonomi.com>
To:        freebsd-questions@freebsd.org, ndhertbsd@gmail.com
Subject:   Re: User can't login but /etc/(master.)passwd OK
Message-ID:  <201205091503.q49F3xwH004097@mail.r-bonomi.com>
In-Reply-To: <CAEFCw4s-SgXe4mmqGACFE6N9JUvANc019hji-dnG=h%2Bx_tDSdQ@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
> From owner-freebsd-questions@freebsd.org  Wed May  9 07:09:19 2012
> Date: Wed, 9 May 2012 14:04:35 +0200
> From: n dhert <ndhertbsd@gmail.com>
> To: freebsd-questions@freebsd.org
> Subject: User can't login but /etc/(master.)passwd OK
>
> I have a problem with a login on FreeBSD (8.3-p1)
>
> Dont' know what was done wrong, but a certain user (lets call it
> THATUSER) can no longer login.
>
> the entries for 'THATUSER in /etc/passwd and /etc/master.passwd are still
> the same as from a backup
> of 14 days ago (no change in encrypted passwd)
> The /etc/pwd.db and /etc/spwd.db  are binary files so I can't check..
>
> The home-directory of THATUSER is still present and contents looks normal ..

"Details are *IMPORTANT*" <grin>

What is shown for the 'owner' useraame/groupname for files in that directory?

What does a long-form listing of the entry for the home-directory _itself_
show?  Specifically with regard to the 'owner' username and groupname?

> All users have quota, but for this particular user:
> # quota -v THATUSER
> responds
> quota: THATUSER: unknown user
> # edquota -u THATUSER
> edquota: THATUSER: no such user
> # repquota /home does not show that user anymore
>
> Other users, no problem
> So it seems that user is unknown to the system ??
>
> What can be the reason and how to solve ?

All of this suggests that user THATUSER is -not- the "name" that you "think"
it is.

Possibly that some glyph in THATUSER is not in the ASCII set, but is an
'extended' character  that 'looks like' an ASII symbol in what you are
keyboarding to represent THATUSER.

*OR* that there is 'whitespace' preceeding/following THATUSER.

*OR* that there is an embedded {char}[BS] sequence.

Does 'grep THATUSER /etc/passwd' produce a user line as you expect?

IF so, does 'grep THATUSER /etc/passwd | od -xc' show anything
'unexpected'?

How about the same checks on /etc/master.passwd ?










Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201205091503.q49F3xwH004097>