This article, the third and final part of our system values series, explores how to reclaim unused spool storage, change the date and time of the system, and change library lists.
This article completes my exploration of the AS/400 system values. Many of them, such as automatic configuration (QAUTOCFG), can make our lives easier if we use them correctly. Others, such as performance adjustment (QPFRADJ), require thought and analysis.
Lets look at some more system values to see what they can do for us.
Most of us yearn for better system performance; we constantly look for tips to help increase response time. Well, heres a tip for you: Look at the system value that controls the initial total number of active jobs on the systemQACTJOB.
QACTJOB sets an amount of DASD storage for jobs on the system when your machine IPLs. If this value is set so low that your AS/400 exceeds the total number of jobs, the system has to stop and allocate more DASD, which slows down your system. If this value is set too high, you could be wasting valuable resources. If you set this value properly, the system slows down only at IPL to set up these resources. Most programmers IPL when use of the system is low and few or no users are signed on, so be sure to set this value high enough to avoid forcing the system to allocate resources during peak periods.
How do you know how much is enough? First, use the Work with Active Jobs (WRK-ACTJOB) command (or the corresponding API, QUSRJOBI) to look at the total number of user jobs. View this display at peak times to accurately assess system usage. Second, use IBMs Performance Measurement 400 (PM400). PM400 reports the highest number of active jobs found during a given time period. This service is free for up to two reports a year. You will have to pay for more reports. Third, use performance tools (5769- PT1) to find your value. PM400 is my preferred option.
Whatever your method, find your value, add 10 percent to it, and use that number as the value for QACTJOB.
If your system exceeds the maximum number of active jobs, it will use another system value, additional number of active jobs (QADLACTJ), to automatically increase DASD. Set this value to 20 percent of your QACTJOB value.
Note that these percentages are not scientific. They are estimates that I have come up with over the years.
Set the next system value, the total number of jobs (QTOTJOB), in the same manner as QACTJOB by using the Work with System Status (WRKSYSSTS) command, performance tools, or PM400 to determine the total number of jobs (active, spooled, queued, and disconnected). If the system reaches this number of jobs, it uses the additional number of total jobs (QADLTOTJ) system value to increase DASD. When this happens, depending on your system and your system load, you may notice that the AS/400 seems to be slow or even frozen, and you have to wait for your next screen to appear. As with active jobs, find the maximum number and add 10 percent for QTOTJOB. Take 20 percent of that for QADLTOTJ.
You can turn the dynamic priority scheduler on or off with the QDYNPTYSCD system value.
1on The task scheduler uses this system value to schedule jobs. For each job on the system, the AS/400 ships with an initial size of 3,516 bytes for the spooling control block system value (QJOBSPLA). This value allows for two spooled files per job. If this value is set lower than 3516, the system actually uses 3,516 bytes. If you need more spooled files, set the value at 9600, which will give you about eight spooled files per job. This value usually impacts only performance, not DASD storage.
Youve probably noticed that some jobs have only one job log and others have multiple job logs. QJOBMSGQMX sets the maximum amount of storage that a job log can have (the value is in megabytes). Once that value is reached, QJOBMSGQFL decides what action to take.
*NOWRAPDo not wrap the job log; end the job when the value specified in QJOBMSGQMX is reached. (Ouch! This dangerous value is the default.)
*WRAPWrap the job log. You could lose vital information with this value; the oldest data simply vanishes.
*PRTWRAPWrite the job log out to the specified queue, and start another log. Id definitely use this value.
Date and Time
The AS/400 (unlike me) handles time changes in the spring and fall easily. There are five values that tie specifically to the date.
QDATEThis is the system date in either five or six characters, depending on the system date format (QDATFMT), which Ill discuss later. If that format is any combination of the year, month, and day formats, this value must be six characters. If the date format is Julian, it must be five characters.
Changes to these date values affect the job scheduler. If the time is set back, jobs that have been scheduled to already run will not be rescheduled. If the date is set forward, OS/400 combs the scheduler to see what (if anything) was scheduled to run between the current time and the changed time. Those jobs are run according to their entries and submitted all at once.
Dates are supported between the dates of August 24, 1928 and July 6, 2053. QDATE consists of more values that can be changed by themselves:
QYEAR This value is the year subset of QDATE.
QMONTHThis value is the month subset of QDATE. You can change this value if the date format is not Julian. The range is 1 to 12.
QDAYThis value is the day subset of QDATE. If your date format is Julian, the valid range is 1 to 366 (366 for leap year). If your date is not Julian, the valid range is 1 to
31. The system checks for invalid dates, such as February 29 and June 31.
QCENTURYIf the date is between 1928 and 1999, the century value is 0. If the date is between 2000 and 2053, the value is 1. I guess that IBM will have to modify the definition of this value sometime within the next 55 years.
The day of the week (QDAYOFWEEK) value is a display or output-only value. It reflects the day of the week of QDATE, ranging from *SUN to *SAT.
If you use a calendar other than the Gregorian calendar, you may need to change the leap year adjustment (QLEAPADJ) value. Generally, it is set to 0 and should be left as such. If you use a non-Gregorian calendar, divide that year by four and use the re-mainder as this value.
QTIME is the time of day. Fortunately, our predecessors have not given us multiple time formats. QTIME, like QDATE, can be changed by itself or in three other variables: QHOURThe hour subset of QTIME
QMINUTEThe minute subset of QTIME
QSECONDThe second subset of QTIME QTIME has one format, hhmmss, where hh is the hours in a military (24-hour) clock, and mm and ss are the minutes and seconds respectively. Unfortunately, we cannot set the milliseconds of our AS/400, but they can be retrieved. Thanks, Rochester!
You can set your AS/400 to your time zone. For example, there is a three-hour difference between the time in my hometown of Bristol, Virginia, and the time at Midrange Computing in Carlsbad, California. When Bristol is busily starting a new day, Carlsbad is still sleeping.
Bristol is minus five hours from Universal Time Coordinated (UTC) or Greenwich Meridian Time (GMT). Likewise, Carlsbad is minus eight hours. The universal time offset (QUTCOFFSET) system value can set such a difference for you. Its format is five characters: one for a plus (+) or a minus (-), two for hours, and two for minutes. My AS/400 is set at -0500; Midrange Computings AS/400 is set at -0800. Using QUTCOFFSET, you can calculate the time difference between your AS/400 and AS/400s in different time zones. (You may have noticed that email time stamps work similarly.)
In the date and time section of this article, I covered some system values only briefly. Heres a more thorough explanation.
The date format (QDATFMT) system value can be set to the following values:
YMDyear, month, day
MDYmonth, day, year
DMYday, month, year
JULJulian (YYDDD where YY is the year, and DDD is the sequential day of the The currency symbol (QCURSYM) system value sets the dollar notation used in the system. It can be any character except a minus sign (-), an ampersand (&), a semicolon (;), an asterisk (*), or 0. It is used when an output file uses the DDS keywords edit word (EDTWRD) or edit code (EDTCDE).
The date separator (QDATSEP) system value is used as a default for jobs in the system. It can be changed within a job. These are the valid values for separators:
2Minus sign (-)
5Blank ( ) The decimal format (QDECFMT) sets the comma and decimal parameters for your system.
BlankThis value uses a period for the decimal point and a comma for the three- digit grouping. Zero suppresses any zeros to the left of the decimal point.
JThe reverse of the blank, this value uses a comma for the decimal point and a period for three-digit grouping. It has at least one 0 to the left of the decimal point.
IThis value is similar to J, but it has zero suppression to the left of the decimal The J and I values are for standards used by countries other than the United States. The time separator (QTIMSEP) can have these values:
In a WRKSYSSTS display, the base storage pool (system pool 2 in Figure 1) has two parts that can be controlled via system values: the pool size (QBASPOOL) and the base activity level (QBASACTLVL). If you have the performance adjustment system value (QPFRADJ) set to 1, 2, or 3, it can change these values; a change on WRKSYSSTS can also change these values.
The machine pool (QMCHPOOL) system value, like QBASPOOL and QBASACTLVL, can be changed via the performance system value or WRKSYSSTS. The machine pool is always pool 1 (as shown in Figure 1). You cannot set a value for the activity level of the machine pool.
However, you can set the maximum number of jobs that compete for resources (QMAXACTLVL) in the system. The values range from 2 to *NOMAX. I think 2 is too small for any AS/400. A value that is too small results in an excessive amount of waits for jobs that need resources. *NOMAX could cause degradation in performance in the other direction. PM400 can help you determine how to set this system value as well.
One of the tuning tools you can use in your system is the time slice end pool (QTSEPOOL). This specifies whether an interactive job moves to the base pool when its time slice ends. A change to this value affects only jobs entering the system after the value is changed, not currently running jobs.
*NONEDoes not move
Two values control your library list when you first sign on. Programs called after sign-on can modify that list, though. The system part of the library list (QSYSLIBL) and the user part of the library list (QUSRLIBL) values set the users library list immediately after sign-on.
Use caution when setting these values. You cannot delete a library when its in use, and you cannot delete any library in a users initial list unless a change is made in the list or the user signs off.
QSYSLIBL can have up to 15 libraries, and QUSRLIBL can have up to 25.
As users discuss how much they use the system, they often complain that they need faster response time. You can monitor system use with the accounting level (QACGLVL) system value.
*NONEno accounting information written to a journal
*JOBJob resource use written to a journal
*PRINTPrint file resource use written to a journal
*JOB and *PRINT can be used together. To perform job accounting and journaling, you must have a journal named QACGJRN in library QSYS and an associated receiver that can reside anywhere on your system. Next, look to the user profile to create an accounting code.
Each AS/400 has a history log, and you can control how many records you want in a single log. The maximum number of records in each history log is set in QHSTLOGSIZ. Once this value is reached, a new log is created. You can display the logs with the Display History Log (DSPHST) command.
The problem filter (QPRBFTR) system value specifies the name of the filter object used by the service activity manager. The maximum number of days that a problem can be kept (QPRBHLDITV) is from 0 to 999 days.
If you use separator pages, set the print text (QPRTTXT) on these separator pages to either nothing (*BLANK) or up to 30 characters of text.
You can log software errors, or not, by setting the QSFWERRLOG value. The values are *LOG and *NOLOG.
The service dump QSRVDMP system value allows you to control whether the Dump in Progress message on line 24 of the screen is seen or not.
*NONENo dumps in any jobs
*DMPSYSJOBService dumps for only system jobs
*DMPUSRJOBService dumps for only user jobs
*DMPALLJOBService dumps for all jobs The QSTSMSG system value determines whether status messages, which also appear on line 24 of the display, are displayed.
*NONEDo not display
The Value of System Values
This article concludes the series on system values. My object was to provoke some thought and (hopefully) to cause you to review your own system values. If you are like me, you have upgraded to a new release of the operating system at least once since you last took a hard look at your system values. Some have crept in on you. I learned a lot by writing this series, and I hope that you benefited from it.
You can find the complete table of system values from this series on the Midrange Computing Web site at http://www.midrange computing.com/mc/98/09.
OS/400 Work Management Guide V4R1 (SC41-5306, CD-ROM QB3ALG00)