[99096] in RedHat Linux List
Re: Help administration
daemon@ATHENA.MIT.EDU (Tomas Buday)
Thu Nov 12 09:59:01 1998
Date: Thu, 12 Nov 1998 15:59:09 +0100 (CET)
From: Tomas Buday <tomas@snt.sk>
To: redhat-list@redhat.com
cc: redhat-digest@redhat.com
In-Reply-To: <364B1F16.81D5D88E@suffolk.lib.ny.us>
Resent-From: redhat-list@redhat.com
Reply-To: redhat-list@redhat.com
i guess one way to accomplish this task is
to create a file containg the new login names
and then run a script similar to the following:
#--------------------------------------------
for user in $(cat file_containing_new_logins)
do
adduser -d /home/users/$user -s /bin/bash $user
passwd $user
done
#--------------------------------------------
...you can add other options to the adduser command.
the scrip will always prompt you for a password....can
this be done automatically???
"passwd user</password" says Conversation Error
(/password contains the password (two words on separate
lines)
dont forget to make the script executable (chmod 700).
On Thu, 12 Nov 1998, Mario Fernandez wrote:
> Hi, I work for a educational environment and part of my duties as
> administrator is to create users (hundreds of them) every semester, I
> was wondering if you guys can share with me a utility or script that can
> create the users automatically just reading the social security number
> of the user and assign a user ID and Email account like in a batch
> processing. Currently I'm doing it one by one and its a pain in the b...
> to do it. Please if you can't help me can you tell me where can I get
> more info. about shell free scripts. Thank you...
> Mario Fernandez.
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com http://archive.redhat.com
To unsubscribe: mail redhat-list-request@redhat.com with
"unsubscribe" as the Subject.