You are on page 1of 2

MVS TOOLS AND TRICKS

Timing Out
BY SAM GOLOB

C
hances are, most of you haven’t had TSO sessions in the middle of their activity. region requested for a job step cannot
the system programmer’s “silver spoon” We’ve all heard of canceling or forcing be obtained.
in your mouth for your entire data jobs and TSO sessions. When a job pro- ◆ A System 922 ABEND occurs if the
processing career. In other words, you proba- duces excessive output, we might want to INITIATOR is now in control of a job,
bly haven’t had “PC (Privileged Character)” chop it off before it floods our printing before or after the job step has taken
status. One of the features of PC status is resources or JES spool space. CPU time place, and an ABEND or other inter-
that your own TSO session does not “time excession ABENDs have occasionally ruption occurs.
out” and get logged off with a System 522 been part of our experience. Sometimes, ◆ A System A22 ABEND occurs after
ABEND after a designated number of we run a big SMP job in the wrong class a FORCE operator command was
minutes of inactivity. You can leave the and it exceeds that class’ allowable CPU issued, and the address space was
office and stay logged on all day. time, getting cut short in the middle. All of “burned”, or chopped off forcibly, no
From the administrator’s point of view, this these “cutoffs” are related by the fact that matter what it had been doing before.
privilege of not timing out is undesirable for the resulting system ABENDs nearly all
the “average” TSO user. Therefore, in most end with the characters ‘22’. We have faced nearly all of these
installations, such power is not given to these What are some of these System X22- ABENDs in our careers. Sometimes we are
users. Why is it better that an average TSO type ABENDs? happy when one occurs. Other times, we
user should not time out? First, any logged- can be very disappointed. This month, I’ll
on TSO user allocates a certain number of ◆ A System ABEND 122 occurs when the talk about a few tricks we can do to avoid
datasets and ties them up with a shared operator cancels a job, requesting a dump. some of these disappointments.
enqueue, so no one else can get an exclusive ◆ A System ABEND 222 is an oper ator Please remember that, by and large, we are
enqueue to these datasets if needed. Second, cancel without a dump, which is very PCs (Privileged Characters) in our profes-
even a swapped-out TSO user is tying up an common. sion. However, sometimes management feels
address space and some system resources; ◆ A System ABEND 322 is a CPU time even we PCs need to be restricted.
this user might even stop a new user from excession cancel of a job. Nevertheless, we still are the system doctors,
logging on, if the MAXUSERS number (of ◆ A System ABEND 422 is new, and is and we still need our tools to do the job that
logged-on users) is being approached. Third, similar to a 222, but it is done by an management asks of us. This scenario is
if that TSO session is being hung while no Open Systems MVS application. similar to what the parent demanded of the
one skilled is around, it would be very diffi- ◆ A System ABEND 522 results from school bus driver: “Be careful and drive
cult to free the session. You can probably excession of the Job Wait Time (JWT) slowly, but get my child to school quickly.”
think of several other reasons that an parameter in the SMF parms in The bus driver still has to get that child to
automatic session time-out would be helpful SYS1.PARMLIB. This is the “timing school, safely, despite the parent’s protests.
for most TSO users. Of course for us PCs, out”ABEND we will examine this And we have to do the job that management
none of these reasons apply, since we can fix month. A System 622 ABEND occurs requires of us, safely, but quickly too, without
any problem we might cause. Yeah, right. when something goes wrong with TSO, unnecessary hassles and interruptions.
Anyway, this month’s column will examine or your session gets disconnected from So if management does not allow us to
this idea of timing out. the terminal and the reconnect limit stop our sessions from timing out with a
time passes. S522 ABEND, and the job requires that we
X22-TYPE ABENDS ◆ A System 722 ABEND occurs if the job have to run several parallel sessions on one
My opinion is that this subject should puts out a lot of output, exceeding the or more systems for an extended period of
really start with a discussion about pur- JES or JOB card output limits and the time, without their timing out, what option
posely killing an address space. IBM has OUTLIM parameter was not coded in do we have? How can we circumvent our
graciously provided us with several means the job’s JCL to override these limits. management’s restrictions and still do the
of “chopping off” jobs, started tasks, and ◆ A System 822 ABEND occurs when the job asked of us?

http://www.naspa.net June ‘97 TECHNICAL SUPPORT


WAYS OF AVOIDING SYSTEM 522 ABENDS be implemented with management approval File 183 (non-reentrant and non-reusable)
A System 522 ABEND is often caused operates through RACF or whatever security into this private library. With ISPF running,
by a TSO session’s inactivity. How long it package you have. I’ll show an example your TSO session will not time out during
takes to trigger the time-out depends on the using RACF. You define an entity to RACF in weekdays, until 7 p.m. on Friday. Examine
setting of the Job Wait Time (JWT) parameter the FACILITY class called TSOWAIT. Those the source code of the ISPTASK module on
in the SMFPRMxx member of SYS1.PARM- users who will not time out are given READ File 183 to see how this works. You can
LIB (in minutes). All non-altered TSO ses- access to this entity. Then an IEFUTL exit alter the source code if you have different
sions will time out in this determined number can be coded, which does a RACROUTE call timeout exemption requirements.
of minutes. How can we override this time- for the TSO user to ask if READ access is The user version of the ISPTASK module
out in our own TSO session and not affect granted to this entity, and if so, an infinite from File 183 is designed to front-end IBM’s
the average TSO user? time extension is given to the TSO session. ISPTASK module, which is either in the
One way to avoid the time-out is to have Management administers this solution offi- link list or in LPA. IBM’s ISPTASK module
your own TSO logon procedure in a PROC cially, through the security administrators, is re-entrant; this user front-end is not. The
library. This would also require that and everything is above board. user ISPTASK, as coded, works as follows:
SYS1.UADS or a security package (i.e.,
RACF, ACF2, TOP-SECRET, etc.) be set up 1. Upon getting control, it pre-loads a
so the use of your own procedure would be One of the features of PC bunch of ISPF modules into the Job
allowed when your ID is used to logon to (Privileged Character) status is that Pack Queue for more efficient operation
TSO. Your own logon procedure, which, in if these modules were not put in LPA-
effect, is JCL, can be then coded with your own TSO session does not “time LIB, but were running from the link
TIME=1440 or TIME=NOLIMIT in the out” and get logged off with a System list. This is not important for our
EXEC card which invokes the terminal mon- 522 ABEND after a designated purpose, but I’m just mentioning it
itor program (usually IKJEFT01 or for completeness.
ADFMDF03). This will override a short number of minutes of inactivity. 2. Afterwards, our user ISPTASK determines
JWT setting and keep your own TSO session what day of the week it is (Monday
“on the air”. through Friday) and conditionally passes
Some installations do not allow this, This IEFUTL exit can be quite easily control to the STIMER routine that jogs
although nowadays it is unusual to find such coded. An example can be found on File 245 the TSO session into “activity” every
“backward” places. These installations, while of the CBT MVS Utilities Tape, a huge, inde- 10 minutes. It only does this from
recognizing that systems programmers have pendently produced tape of MVS goodies Monday at midnight until Friday at 7 p.m.
different requirements in their TSO sessions available through NaSPA. The IEFUTL exit 3. Finally, it does a lot of searching
than application programmers, will allow one in File 245 can be simplified even further. through TCBs, looking for IBM’s
logon PROC for application programmers Besides the RACROUTE call there is very actual copy of ISPTASK, avoiding
and another one (or several) for systems pro- little to it, just either a time extension or a ISPLLIB and STEPLIB, looking for
grammers. They will not allow, however, a bypass of the time extension, based on the a re-entrant module.
systems programmer to have a private logon result of the RACROUTE call. If you have 4. Upon finding the proper copy of
PROC. And they will also not allow other IEFUTL exits in use at your installa- ISPTASK, it XCTLs to it. Meanwhile,
TIME=1440 or TIME=NO-LIMIT to be tion, don’t worry. SMF exits can be easily the STIMER keeps popping itself every
coded in any of these PROCs. In many places, piggybacked, so they all run in succession. 10 minutes, and the TSO session does
the systems programmers are not the security not time out, because of this “activity”.
administrators. What can we do now? ANOTHER SOLUTION
A common solution is to find (or write) Another clever solution can be found on I hope you have found this month’s
a program which runs continuously in a File 183 of the CBT MVS Tape. This solu- discussion interesting and info rm at ive.
TSO session if nothing else is running, and tion requires that ISPF be running in your Perhaps you will find alternative ways to do
that has a built-in timer. For example, the TSO session. To implement this solution this job. I’ve always thought that systems
timer will pop every five minutes. When the judiciously, not including too many people programmers were a clever bunch. Good
timer pops, the program triggers some in the timeout exemption, you should have luck, and keep those timers popping. See
small TSO activity to fool the session into a restricted or a private load library to put you next month. ts
thinking that it is not inactive. Therefore, into the ISPLLIB concatenation. This can
the session will never time out. be done dynamically in a CLIST using the
There is a way to solve this problem with ALLOCATE TSO command, even if your NaSPA member Sam Golob is a senior
management’s approval. If your installation TSO session is using a public logon PROC. systems programmer.
sufficiently recognizes the importance of cer- Just exit ISPF, FREE FILE(ISPLLIB), and
tain users not timing out, there is another pos- issue an ALLOCATE command with the ©1997 Technical Enterprises, Inc. Reprinted
sible approach via the SMF exit IEFUTL that proper ISPLLIB libraries concatenated in with permission of Technical Support maga-
can be used to control the effect of Job Wait the proper order. That can all be done in one zine. For subscription information, email
Time on jobs, started tasks, or TSO sessions. CLIST. Finall y, assemble and linkedit the mbrship@naspa.net or call 414-768-8000,
An interesting and general solution that can source code for the ISPTASK module on Ext. 116.

TECHNICAL SUPPORT June ‘97 http://www.naspa.net

You might also like