[lug] Adding Users -- Yellow Dog PPC

Lynn Danielson lynnd at techangle.com
Mon Nov 8 15:30:23 MST 1999


The man page for useradd says that the -p switch accepts "the encrypted
password, as  returned  by  crypt(3).  The default is to disable the 
account."  I don't know that I've ever tried to set passwords with it,
but if you've already created an account and simply have a bad passwd or
a disabled account, you should be able to edit your passwd (or shadow) 
file as super user and remove all the characters in the encrypted 
password field, that is the second field between the first two colons.
I believe an asterisk in that field indicates a disabled account.

Or you can create a new user the hard way.

Add new line to your /etc/passwd (and /etc/shadow if appropriate) for 
the new user leaving the password field empty.  If you have a shadow
password system you should see an "x" in the second field of
/etc/passwd.
Create the home directory as set in /etc/passwd.  Chown the home
directory
for for the appropriate username:group.  Su to the user, copy all files
from /etc/skel to the home directory and set a password.

Lynn Danielson


"Pedersen, Michael J" wrote:
> 
> By my understanding of useradd, you can't use create a password for a user
> with it.  You have to run passwd on the user after you've created teh user
> to manually set the password.
> 
> I haven't used useradd for several years, so my understanding of proper
> usage may be incorrect.
> 
> > From: root [mailto:briank at becos.org]
> >
> > OK, I feel pretty stupid, but I can't seem to add a user in Yellowdog
> > Champion 1.1   I use Useradd to add a user with a password
> > and then when I
> > try to log that user in it tells me that the password is
> > incorrect.  Should
> > there be a space between the '-p' and the password in the
> > useradd command?
> >
> > On a much higher note, Linux runs like greased lightening on
> > my G4 - 400 /
> > 128MB RAM.  Just plain fast.




More information about the LUG mailing list