- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Script to reset NIS users Password
Operating System - Linux
1822895
Members
3894
Online
109645
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2007 04:54 PM
11-10-2007 04:54 PM
Script to reset NIS users Password
Hi Experts,
I need a script to reset the NIS users password .Here is the procedure currently we are following to reset passwords.
• On Master server enter “passwd -r files -F /etc/passwd userid”
• The new password should be the first three letters of the userid plus “-01”. Example: userid: minyard password: min-01
• Edit the /etc/password file and back-date the aging character by one week. This is the third character after the comma in the password field. The aging character will be a letter from a-z or A-Z, hence 52 possibilities. This will enable the user to immediately change his/her password to something more secure. Here’s an example of what you should change.
pilzj:uBNMQ/dq5Wi6I,O.gR:1723:125:JonPilz,,,:/home/app/users:/usr/bin/sh
pilzj:uBNMQ/dq5Wi6I,O.fR:1723:125:JonPilz,,,:/home/app/users:/usr/bin/sh
• Run “/var/yp/ypmake” to push the changes.
I need a script to reset the NIS users password .Here is the procedure currently we are following to reset passwords.
• On Master server enter “passwd -r files -F /etc/passwd userid”
• The new password should be the first three letters of the userid plus “-01”. Example: userid: minyard password: min-01
• Edit the /etc/password file and back-date the aging character by one week. This is the third character after the comma in the password field. The aging character will be a letter from a-z or A-Z, hence 52 possibilities. This will enable the user to immediately change his/her password to something more secure. Here’s an example of what you should change.
pilzj:uBNMQ/dq5Wi6I,O.gR:1723:125:JonPilz,,,:/home/app/users:/usr/bin/sh
pilzj:uBNMQ/dq5Wi6I,O.fR:1723:125:JonPilz,,,:/home/app/users:/usr/bin/sh
• Run “/var/yp/ypmake” to push the changes.
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-10-2007 06:10 PM
11-10-2007 06:10 PM
Re: Script to reset NIS users Password
Shalom,
We reset the password to blank and force a change on then next login. We set a seven day period to use or lose the ID.
Security policy is set on the NIS master in /etc/default/security
ypmake is used by the scripts that do this.
The empty password script contains information on our internal setup, so I can't easily post it. The rest are simple passwd commands.
passwd -f username # forces a password change next login.
passwd -x 7 # makes this account live for only seven days before its inactive.
SEP
We reset the password to blank and force a change on then next login. We set a seven day period to use or lose the ID.
Security policy is set on the NIS master in /etc/default/security
ypmake is used by the scripts that do this.
The empty password script contains information on our internal setup, so I can't easily post it. The rest are simple passwd commands.
passwd -f username # forces a password change next login.
passwd -x 7 # makes this account live for only seven days before its inactive.
SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP