Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Feb 1999 10:57:45 +1000
From:      Greg Black <gjb@comkey.com.au>
To:        Mark Ovens <marko@uk.radan.com>
Cc:        Langa Kentane <LKentane@mweb.com>, freebsd-questions@FreeBSD.ORG, ruan@ctech.ac.za
Subject:   Re: Can't change shell - Please help newbie 
Message-ID:  <19990221005745.7091.qmail@alpha.comkey.com.au>
In-Reply-To: <19990220124307.E185@localhost>  of Sat, 20 Feb 1999 12:43:07 GMT
References:  <913B8C252194D2119BD500805F318178030416@za12nt02.mweb.com> <19990220124307.E185@localhost> 

next in thread | previous in thread | raw e-mail | index | archive | help
First, please trim the irrelevant elements of posts that you
respond to (see the regular article about how to get the best
from the list if this is a puzzle).

> How are you editing the password file? If you are just editing
> /etc/passwd it won't work. Use vipw(8). When you save and exit vipw
> re-builds the passwd database.

It might be useful to explain why editing /etc/passwd is no use,
since that has been for many years (and still is, in many cases)
the canonical way to do these things.

FreeBSD (like many other modern systems) provides both "shadow"
passwords and a variety of extra fields that are not part of the
traditional /etc/passwd file.  All this magic is contained in
the new passwd file (/etc/master.passwd) and this is the file
that must be edited (using vipw) for changes to take effect.

After the editing is done, vipw does what is needed to update
both /etc/passwd and the hashed database files -- which are the
files that are really accessed by all the lookup routines.

RTFM for a fuller description, starting with passwd(5).

-- 
Greg Black <gjb@acm.org>



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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