Have you ever wanted to find out which users have not signed on in the past 90 days or how many users are on the...
system? This tip will show you how to get all kinds of information about your user profiles.
Create an OUTFILE of all user profiles defined to the system using the DSPUSRPRF command:
DSPUSRPRF USRPRF(*ALL) OUTPUT(*OUTFILE) OUTFILE(yourlib/USRPRF)
Use the "Display File Filed Description" command to see the field names available in the yourlib/usrprf OUTFILE:
Start getting answers to your questions by analyzing this OUTFILE.
You can see how many total user profiles exist on your system by looking at how many records are in the yourlib/usrprf file. Use the "Display File Description" command:
DSPFD FILE(USRPRF) TYPE(*MBRLIST)
To determine who hasn't signed on in the past 90 days, use SQL or the iSeries Query Utilities (STRQRY) to query the yourlib/usrprf OUTFILE:
Select fields: UPUPRF (User Profile Name) UPPSOD (Previous sign-on date: YYMMDD)
Sort on UPPSOD in ascending order. This will list all the user profiles in the order of the previous sign-on.
Note: If UPPSOD is "blank," then this user profile has never signed on.
Use query or SQL to answer just about any question you might have about user profiles on your system. All the data you need is now at your fingertips, in the OUTFILE yourlib/usrprf.
About the author: Kenneth Graap is a senior AS/400e system administrator at Northwest Natural Gas in Portland, Ore. He has extensive experience in all aspects of iSeries systems management. That includes proactive performance tuning, system software upgrades and maintenance, hardware upgrade planning, backup/recovery procedures and security.