Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I want to have a script to force the users to regularly change the login password on RH 8 , anyone can post the script for me ?
I tried chage , it is great problem , it don't allow two users or above to change password at the same time , it will hold at the below screen , can suggest what is wrong in our system ? thx
login: user2
You are required to change your password immediately (root enforced)my command is
# chage -d0 userid1
# chage -d0 userid2But when userid1 is changing the password, then userid2 can't change the password at the same time , we have about 200 users so it is a great problem of us , can suggest how to solve it.
i tried -M0 , but it still have the same problem , it don't allow two users change the password at the same time - when a user hold at the change password screen , then other user can't change the password at the same time , is there other solution ? thx

Why use a script? You can set passwords to
expire after x amount of days so the user
has to change them...."man passwd" for more
details.

Thx reply , but how to send the warning message to the user (eg. 5 days )before the password expiry ? thx.

Use the "-w" switch to set the amount of
warning days before the expiration date. Eg
to set a password to expire after 30 days
with a 5 day warning:
# passwd -x 30 -w 5 username

Thx reply , but my problem is the warning message will be disappear very fast , the user can't read the message , hv you encounter the same problem ? can suggest what can i do ? thx.

I run RH8 text mode , what is your linux version ?
In my RH8 , no passwd -x function , what is our difference ? can suggest other solution ? thx.

I'm running slackware 9.0 with a text
login. Here is what I get when logging in
as a test user with the password set to
expire in one day:
davidhume login: test
Password:
Linux 2.4.20.
Last login: Thu Aug 21 12:50:27 +0100 2003
on tty2.
Your password will expire tomorrow.
No mail.
test@davidhume:~$
The "Your password will expire tomorrow"
stays on the screen above the prompt.
Perhaps your system is clearing the screen
just before displaying a shell
prompt...look in your profile and bashrc
files.
If I type "passwd -x" with no other options
I receive:
passwd: option requires an argument --
x
I have also noticed that kuser can also set
expiration days for passwords....if you
have KDE installed you could give that a
try.

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |