Operating System - Linux
1830192 Members
4891 Online
109999 Solutions
New Discussion

Re: Alert user password change

 
SOLVED
Go to solution
juno2
Super Advisor

Alert user password change

Hi all,

We will regularly change the user password on our RH8 server , we usually send the mail to users to Alert them the password will be expired , except use the mail, how can I alert the user ( eg . when the user login) about the password will be expiried ? thx in advance.
1 REPLY 1
James Specht
Trusted Contributor
Solution

Re: Alert user password change

Juno, I must admit to not fully understanding your question. But I will give it a shot.

Are you forcing the passwords to expire manually or do you have the system doing this for you?

In either case the next login by the user would let them know to change their password. So this is where I get confused. I'll assume you want to notify them before the password change is forced by the system. If that is the case simple edit your /etc/profile and add this line.

[ -f /etc/warningusers ] && cat /etc/warningusers

Now once you create the /etc/warningusers file users will see the contect of the file during login. In the warningusers file you can have a little blurb about when the passwords will expire. Once you expire the passwords rename the /etc/warningusers file so you stop warning them.

Hope I helped.

--Jim
"Everyone can be taught to sculpt: Michelangelo would have had to be taught how not to. So it is with the great programmers."