Insight 204 USE OF AND ACCESS TO PRODUCTS AND FEATURES ARE IN ACCORDANCE WITH THE TERMS AND CONDITIONS OF THE USERS SOFTWARE LICENSE. THE PRESENTATION OF MATERIAL HEREIN DOES NOT, IN ANY MANNER, MODIFY SUCH TERMS AND CONDITIONS.
LAST CHANCE to Register for Insight 204! By Marie Kelly Director of Marketing
By this time next month, Insight 204 will be a grand memory, and if you dont register soon, you will have missed it! We have a great conference planned this year and if youre not there, youll wish that you were!
If you havent registered yet for Insight 204, you need to so immediately. With less than three weeks to go, we are finalizing all plans, many of which are driven by headcounts. So be sure to get your reservation in TODAY!
If you plan to stay at the Hyatt, the deadline for making your reservation at the conference rate has passed, but the hotel may still be able to accommodate you. Please visit http://www.cca-int.com/resources/usergroups/insight/lodging05.html today for information on how to contact the Hyatt. Be sure to tell them that you are attending the Computer Corporation of America event.
If you have any questions about Insight 204, please complete the Insight Feedback Form. We look forward to seeing you in Boston in June!
Model 204 USE OF AND ACCESS TO PRODUCTS AND FEATURES ARE IN ACCORDANCE WITH THE TERMS AND CONDITIONS OF THE USERS SOFTWARE LICENSE. THE PRESENTATION OF MATERIAL HEREIN DOES NOT, IN ANY MANNER, MODIFY SUCH TERMS AND CONDITIONS.
Changing Privileges and USE Options for Model 204 Commands By James Damon
The output from many Model 204 commands can be very educational and informative to a wide variety of users: application developers, file managers, DBAs and others who use a Model 204 online system. Many of these commands can be issued only by system managers or system administrators. Many are display only--that is they do not change data or change in any way the operational characteristics of the Online. To promote greater understanding of the Model 204 Online environment, it may be advantageous to provide access to some of these commands to a greater number of users.
Model 204 provides access to the internal command table, so that you can change command privileges and USE options for each command without asking for custom zaps from CCA. For example, if you want to let all users issue the MONITOR command, you can do so without giving all users system administrator or system manager privileges. In addition to allowing the privileges to be changed, the output of each command, when a preceding USE command is in effect, can also be controlled via access to the command table.
Viewing USE and Privileges Options for Each Command You can view the USE options and privileges required for each command by issuing a VIEW COMMAND command, as shown in Figure 1.
Figure 1. Viewing several command table entries
VIEW COMMAND MONITOR*** MONITOR COMMAND USE=RESPECT PRIVILEGE=(SYSADM,LOGONREQ)COMMAND MODEL204 COMMAND TABLE VIEW COMMAND TABLEB*** TABLEB COMMAND USE=RESPECT PRIVILEGE= -(FILEMGR,LOGONREQ,DEFAULTFILE,SINGLEFILE)COMMAND MODEL204 COMMAND TABLE VIEW COMMAND VIEW*** VIEW COMMAND USE=RESPECT PRIVILEGE=(LOGONREQ)COMMAND MODEL204 COMMAND TABLE
Each Model 204 command has a default USE option and PRIVILEGES that are requirements to issue the command. The following list of the USE options are described in detail in the documentation for the RESET COMMAND in the Model 204 Command Reference Manual:
The following list of the privileges required to issue the command are documented in the same place:
The PRIVILEGESDEFAULTFILE, SINGLEFILE, and UPDATEFILEapply to only file commands and are view-only privileges. In Figure 1 the TABLEB command shows the privileges FILEMGR, LOGONREQ, DEFAULTFILE and SINGLEFILE. The DEFAULTFILE privilege indicates that a default file must be established and the SINGLEFILE privilege indicates that the context of the TABLEB command is a single file, not a group.
Changing Entries in the Command Table Going back to our opening example, suppose you want to enable all users to issue the MONITOR command without giving each of them system administrator privileges. Further, even though a USE command may be in effect, you want it ignored when the next command is MONITOR.The following RESET COMMAND command will accomplish this.
Figure 2. Changing the USE and PRIVILEGE options for the MONITOR command
RESET COMMAND MONITOR USE=IGNORE PRIVILEGE=LOGONREQ*** MONITOR COMMAND USE=IGNORE PRIVILEGE=(LOGONREQ)COMMAND MODEL204 COMMAND TABLE
After this command is issued, the only requirement to issue the MONITOR command is that the user be logged on with a valid user ID. Furthermore, if a USE command is in effect prior to issuing the MONITOR command, it will be ignored.
Notes and Caveats These USE options and privileges affect all versions of the MONITOR command including, but not limited to, MONITOR STAT, MONITOR ENQ, MONITOR DISKBUFF, and so on. The same is true for other commands like DISPLAY.
Also,note that the RESET COMMAND command affects the current Online only. It does not permanently change the command table for future runs. Therefore, RESET COMMAND commands are generally placed at the beginning of CCAIN after a system manager or system administrator has logged in. They can also be saved in a User Language procedure,which is included by User 0 immediately after User 0 logs in.
And finally, the RESET COMMAND and the VIEW COMMAND commands are not viewable and not resettable.
In Summary This facility is especially useful in a test, development,or QA environment where security requirements are often less stringent than in a production environment. Many of the MONITOR commands can be very helpful to developers during the development and test phases of application development and, being display only, pose no threat to Online operations.
System 1032 USE OF AND ACCESS TO PRODUCTS AND FEATURES ARE IN ACCORDANCE WITH THE TERMS AND CONDITIONS OF THE USERS SOFTWARE LICENSE. THE PRESENTATION OF MATERIAL HEREIN DOES NOT, IN ANY MANNER, MODIFY SUCH TERMS AND CONDITIONS.
Keep Your Process from Running Out of Memory By Tym Stegner
Recent System 1032 customer support calls have related to the depletion of process memory, notably in the form of Page File quota. This article explores what a Page File quota represents, how it is used by System 1032, and how to tell why your process may be running out of it.
What Is Page File? The Page File is a system-wide resource of pagelets that are used to augment working set allocations to processes. Inactive or lesser-used working set pages are copied to Page File pages, subject to the Page File quota assigned to each process.
The Page File quota is a share of the system Page File assigned to the process expressed in bytes. The Page File quota, plus the working set, comprise the available working memory for the process.
$ show process/quota 3-MAY-2005 13:40:36.49 User: TYM Process ID: 00003C99 Node: CCAAXP Process name: "TYM" Process Quotas: Account name: CPU limit: Infinite Direct I/O limit: 150 Buffered I/O byte count quota: 199616 Buffered I/O limit: 150 Timer queue entry quota: 10 Open file quota: 499 Paging file quota: 247424 Subprocess quota: 10 Default page fault cluster: 64 AST quota: 248 Enqueue quota: 14999 Shared file limit: 0 Max detached processes: 0 Max active jobs: 0$$ show working_set Working Set (pagelets) /Limit=8192 /Quota=8192 /Extent=131072 Adjustment enabled Authorized Quota=8192 Authorized Extent=131072 Working Set (8Kb pages) /Limit=512 /Quota=512 /Extent=8192 Authorized Quota=512 Authorized Extent=8192$
With the advent of larger systems and less expensive memory, a system can run with a larger set of main memory, and should run a correspondingly greater Page File. This increases the potential working memory for a process; the Page File quota is used to augment working set memory on an as-needed, as-available basis.
CCAAXP> show mem/phy/file System Memory Resources on 19-MAY-2005 11:00:36.54 Physical Memory Usage (pages): Total Free In Use Modified Main Memory (256.00Mb) 32768 20494 12075 199 Paging File Usage (blocks): Free Reservable Total DISK$ASP_AXP071:[SYS0.SYSEXE]SWAPFILE.SYS 24448 24448 29568 DISK$ASP_AXP071:[SYS0.SYSEXE]PAGEFILE.SYS 477808 404816 532480 Of the physical pages in use, 4052 pages are permanently allocated to OpenVMS.CCAAXP>
System 1032 often makes use of the Page File quota for many of its operations. Note that when System 1032 requests more memory from the operating system, the operating system decides whether to grant working set memory or Page File pages.
Page File Usage Some operations in the System 1032 environment can use a great amount of memory, including joined and/or sorted PRINT statements, and collection processing. In some cases, so much memory gets requested that OpenVMS will signal that additional memory is unavailable. Most of the time, OpenVMS tells you specifically which process quota you have exhausted. Unfortunately, the Page File quota is not one of those processes. SYSTEM-?-EXQUOTA is the only message that is displayed. If the error is a fatal condition, the process quota deficiency can be determined from the System 1032 error log entry for the event, in the Process Quotas section the Remaining column will be at or near zero.
Otherwise, generally there is insufficient external evidence to tell what your process has exhausted. If you have run in batch, you may be able to tell from the accounting information at the bottom of the batch log, or if interactive, from accounting records, if enabled.
OK, I Am Out of Page File Quota, What Do I Do? Regardless of how you determined it, you have concluded that you have exhausted your Page File quota. How do you keep System 1032 from running out? Why did System 1032 not notice that it was running out and do something?
Usually, the way to avoid running out of Page File quota is to ensure that the process has sufficient quota available. In many cases, a 1025 percentage increase in quota provides enough additional overhead to get over the processing hump that leads to exhausting the necessary quota.
As for System 1032 noticing that it is about to run out of a process quota, it is impossible for the application to predict how much of a resource is required for complex operations. The application can only fail due to having exhausted a process or system quota.
If you find a case where Page File quota is running out and you have already granted large quotas, or even maximum quotas, please contact System1032 Customer Support. We will help to take a look at the process. Be prepared to describe the operating enviornment of the error event, and if possible, provide a reproducible case of the event.
Handling a Page File Size Limitation What to do? Different sites have taken differing approaches. At several sites the successful approach was to divide the work load into smaller tasks. For example, rather than process two million transactions in a single batch job, process only one million at a time in two successive jobs.
Other sites have thrown hardware at a problem. One site I know added physical memory and disk space, then increased the Page File size and process quotas until they actually hit the process wall: their working set and Page File allocation added up to more process memory than was possible for System 1032 to access--the longword limit. In this case, the site applied to System 1032 Support for help in alleviating their shortage.
Recently a site reported a detached process issue. Their process ran for varying lengths of time--averaging multiple weeks of operation--before aborting with memory shortage errors. In this case, we recommended that the site insert the code in Figure A to check the available Page File quota. The suggestion was for the code to automatically cause a restart of the detached process upon reaching a 99 percentage Page File quota usage threshold.
Detecting Lack of Page File Quota System 1032 can access Run-Time Library routines from system images via PL1032 external procedures. Many such routines are presented in the S1032_UTL library, available in the S1032_TOOLS directory. In particular you can use the GETJPI procedure to discover the Page File quota and usage for a process.
The example code in Figure A demonstrates the use of the GETJPI tool to obtain the Page File quota and Page File count for the current process:
Figure A. Illustrating the GETJPI routine
1032> use demoopen library S1032_UTL in S1032_TOOLS readonlyvar xlen,xpid,xquota integervar xresult array (1) of integervar xtx text varying let xpid=$pidcall GETJPI(1038,xpid,,xresult,xtx,xlen)let xquota=xresult(1) call GETJPI(1044,xpid,,xresult,xtx,xlen)print xquota fmt i,8 title "Page File/Quota" - xresult(1) fmt i,8 title "Page File/Count" - (xquota-xresult(1)) fmt i,8 title "Pages/In use"Page File Page File Pages Quota Count In use--------- --------- -------- 250,000 240,768 9,2321032>
(Predefined S1032 variables of GETJPI item codes can be found in S1032_TOOLS:GETJPI.DMC, or the definitions can be located in the OpenVMS documentation.)
The quota value is retrieved first and later used to calculate current page file limit, as the count value shows the remaining Page File quota. Sometimes I find it easier to look at pages used rather than pages remaining.
Such a test could be incorporated at a high level into a recursive process, and force a clean, controlled exit upon reaching a certain threshold of Page File quota usage.
In Summary The codes in Figure A demonstrate a way to trap for one of the more obscure common quota limitations. Other parameters are available via the system services to trap other process quota limitiations. All help ensure sufficient process quotas to successfully operate your System 1032 applications.