Mailinglist Archive: opensuse (2234 mails)
| < Previous | Next > |
Re: [SLE] Mass useradd & password assignment
- From: alexm@xxxxxxxxxxx (alex medvedev)
- Date: Mon, 13 Sep 1999 07:34:51 -0500 (CDT)
- Message-id: <Pine.LNX.4.10.9909130720220.26111-100000@xxxxxxxxxxxxxx>
Hello,
can't you use "expect"?
or (just a thought):
when nobody else changes their password ;-)
change a passwd for one user and copy the second field from /etc/shadow
for that user (the encrypted passwd).
then
# cp /etc/shadow /tmp/shadow.orig --> backup copy...
# cat /etc/shadow | sed 's/\!/sEcOND_fIelD/' > /tmp/shadow
# cp /tmp/shadow /etc
# rm /tmp/shadow
now all new users should have the same passwd.
this will change passwd for all users with "!" instead of passwd though.
i do not know if you want it...
-alexm
On Sun, 12 Sep 1999, George Toft wrote:
> I need to add 25 users to a machine. I have this script to add the users, but
> how do I initilize their passwords without manually entering each user/password?
>
> -------------------------------
> #!/bin/bash
>
> useradd -g ics-184 user1
> useradd -g ics-184 user2
> useradd -g ics-184 user3
> useradd -g ics-184 user4
> useradd -g ics-184 user5
> [snip]
> -------------------------------
> (User's names have been changed.)
>
> Thanks in advance.
>
> --
> George Toft http://gtoft.dynip.com
> Hawaii Pacific University MSIS Graduate Student
> "Investigating the Relationship Between the Total Cost of
> Ownership, Organization Size, Industry, Workgroup Size,
> And the Perception of Value for Workgroup Servers."
>
>
> --
> To unsubscribe send e-mail to suse-linux-e-unsubscribe@xxxxxxxx
> For additional commands send e-mail to suse-linux-e-help@xxxxxxxx
> Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
>
--
To unsubscribe send e-mail to suse-linux-e-unsubscribe@xxxxxxxx
For additional commands send e-mail to suse-linux-e-help@xxxxxxxx
Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/
| < Previous | Next > |