- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: User maintenance
Categories
Company
Local Language
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
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
Community
Resources
Forums
Blogs
- 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-14-2003 04:26 AM
11-14-2003 04:26 AM
User maintenance
I have users created on a trusted system with expire date set.everything is going well.users are deactivated on their expiry date set. then I have to delete them manually from the system.
Now, I need to know is there any way, I can automate the user deletion process.i.e, once the user is expired, then delete the user from the system.
Please let me know is there any way to do it..may be a script could do it..
Thanks,
Sailesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:32 AM
11-14-2003 04:32 AM
Re: User maintenance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:34 AM
11-14-2003 04:34 AM
Re: User maintenance
You can use the directory creation date for their home directory as the timer to check against.
Just write a script to check versus that date and store the value in a variable per user or a file per user.
If your expiration timer is 30 days. write a script to check once a day at midnite or early morning to see if the date. As they reach the deadline then the script will spawn run: userdel -r $USERNAME
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:42 AM
11-14-2003 04:42 AM
Re: User maintenance
When I say I'm deleting the users manually, I'm using "userdel -r".
I need to know some method (useradd option or a script) to permenantly delete the user accounts from the unix box once the user account is expired.
Thanks,
Sailesh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:48 AM
11-14-2003 04:48 AM
Re: User maintenance
I just tested it and it works...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:57 AM
11-14-2003 04:57 AM
Re: User maintenance
As the others have already suggested, of course, put userdel -r command inside your script...
but, what I wanted to add, regarding how the script can detect expired users, I think you could use the command,
"logins -a -l
perhaps more straightforward than looking at their home dir creation date.
- John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2003 04:58 AM
11-14-2003 04:58 AM
Re: User maintenance
logins -a -l
- John