Smart questions
Smart answers
Smart people
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login




Remember Me
Forgot Password?
Join Us!

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips now!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Donate Today!

Do you enjoy these
technical forums?
Donate Today! Click Here

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.
Jobs from Indeed

Link To This Forum!

Partner Button
Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

Reseting all users passwords and login settings

macrun95 (TechnicalUser) (OP)
29 Oct 09 12:39
Due to meeting the requirements of a recent audit, I need to change some of the login parameters (minage, maxage, etc.) on all my lpars.  I also need to reset all the users passwords so that the next time they login they will be required to change it to meet the new parameters.

I've tried several different ways to do this with some scripting and the passwd command but to no success.

Can anyone suggest some easy ways to to do this.  I have 40+ lpars all running AIX 5.3.

Thanks in advance,

Eric
DukeSSD (TechnicalUser)
29 Oct 09 18:47
Show us what you have tried and why it didn't work and we'll try and give you some pointers.

chuser should take care of the min/maxage change and passwd should promt for the reset at nxt login.
chgwhat (MIS)
29 Oct 09 20:39
force user to change password
chsec -f /etc/security/passwd -s user -a "FLAGS=ADMCHG"

Tony ...  aka chgwhat
 
When in doubt,,, Power out...

macrun95 (TechnicalUser) (OP)
30 Oct 09 10:17
This is what I did on my test system.  When I ran it, it prompted me for a password for each user.  I don't want it to do that I just want to force a password change.

users=`lsuser ALL | awk '{print $1}'`
for i in $users
do
passwd $i
done
macrun95 (TechnicalUser) (OP)
30 Oct 09 14:03
This is what I did this time and it worked.  However, instead of using the lsuser command I'm going to create a text file of logins as input.

users=`lsuser ALL | awk '{print $1}'`
for i in $users
do
chsec -f /etc/security/passwd -s $i -a flags=ADMCHG
done
trifo (MIS)
22 Dec 09 6:00
To set the "Change Password" flag, you can use pwdadm command. Also you can reset the passwords of all users using chpasswd command, which reads <username>:<password> pairs from standard input. It can also clear passwd flags, or read encrypted passwords.

--Trifo

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Back To Forum

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close