HPlogo MPE/iX Commands Reference Manual: HP 3000 MPE/iX Computer Systems > Chapter 7 Command Definitions S-SO

SETCOUNTER

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Index

Sets the next value of a specified resource counter, and optionally enables automatic rollback when a specified limit is reached. Duplicate values are avoided.

Syntax

SETCOUNTER[ COUNTER=] [ INSP | OUTSP | JOBNUM | SESSNUM ]
[ ;BASE = num] [ ;MAX = num ]
[ ;SHOW]

Parameters

INSP

Specifies the input spoolid counter.

OUTSP

Specifies the output spoolid counter.

JOBNUM

Specifies the job number counter.

SESSNUM

Specifies the session number counter.

The target counter (INSP, OUTSP, etc.) is only optional if the SHOW option is used by itself to display BASE and MAX values for all counters without changing any of them. For any other form of the command, the target counter is a required parameter.

num

A positive integer. For MAX, num may also equal zero. A non-zero num for MAX must be less than or equal to the maximum possible value for that counter. Those values are:

INSP

9999999

OUTSP

9999999

JOBNUM

16383

SESSNUM

16383

For BASE, num must be less than MAX, except when MAX is equal to zero.

Operation Notes

The SETCOUNTER command allows you to specify limits other than 1 and the maximum possible value of one of four counters (but within that range) You may set limits for one counter with each use of the command and, therefore, you must invoke the command four times to change the limits of all four coutners.

You may also use SETCOUNTER to display the current values of the counters. Only one invocation of the command is necessary to see all current values.

To set a maximum operating value for the specified counter and enable its operation, enter a positive value for the MAX keyword. Specify MAX=0 to disable the operation, that is, the counter's limit is then its maximum possible value. Omitting MAX leaves its previous value in force. Once MAX is reached, the next value tried is the BASE value. If you specify a non-zero value for MAX, it must be greater than the current BASE for the corresponding counter, but less than the maximum possible value

The BASE keyword causes the specified counter to be immediately yanked to the specified value. If you supply a value, it must be less than the supplied or current value of MAX (other than 0), and in any case, less than the maximum possible value. If you do not specify BASE, it is not changed, nor is current sequencing affected.

For each counter, duplicate values are avoided. For example, if #O10 is in use when due to be assigned as the next output spoolid, it is skipped and #O11 is tried. This process continues until an available value is found.

The defaults, established when the system is booted, are MAX=0 and BASE=1. This is for backward compatibility; if these settings are not changed, the system will operate as it does today. These boot time settings can be modified by including one or more instances of this command in SYSSTART.PUB.SYS.

The SHOW option can be used alone to display the current values of BASE and MAX for a specified counter or for all four counters. If used in addition to either BASE or MAX, the value(s) displayed are the new setting(s).

This command may be issued from a session, job, program, or in Break. Any display specified by the SHOW option is breakable, but command operation is not. Any user may execute this command with only the SHOW option to display current values of BASE, Next, and MAX for the specified counter (or all counters if none is specified). When changing either value, this command may be executed only:

  • at a console session,

  • by a user with SM capability, -OR-

  • by any user who has been allowed the use of the SETCOUNTER command with the ALLOW command.

Examples

To display the current BASE, Next, MAX, and maximum possible values for all four counters, enter:

 :SETCOUNTER ; SHOW
Absolute
COUNTER BASE Next MAX maximum

Input spoolid 1 172 16383 9999999
Output spoolid 1 1872 32767 9999999
Job number 1 172 0 16383
Session number 1 2753 0 16383

To limit input spoolids to the same range as their corresponding jobs, enter:

 :SETCOUNTER INSP; MAX=16383

Related Information

Commands

None

Manuals

None

Feedback to webmaster