Hi Dan

Without trying it, I would think this will work for inquiry messages - they are just a message and will have a MSGKEY in then.

There's another tool, watches - you set things up to do something when any message you specify happens. STRWCH is the command.

*Regards*

*Vern Hamberg*

IBM Champion 2025 <cid:part1.r0hTzciC.K08QA3c0@centurylink.net> CAAC (COMMON Americas Advisory Council) IBM Influencer 2023

On 5/12/2025 6:51 PM, Dan Bale wrote:
Thanks for finding that. I'm not sure that will work for a message that demands a response. Will it?

Since I first posted, I was reminded of the system reply list. Which can work for this scenario if I can capture that the message was issued.

RtvJobA Type( &Interactiv ) InqMsgRpy( &InqMsgRpy )
CHGJOB INQMSGRPY(*SYSRPYL) /* Answer CPA2611 with 'C' */
VRYCFG CFGOBJ(&F1_ODOBNM) CFGTYPE(*CTL) STATUS(*OFF)
CHGJOB INQMSGRPY(&InqMsgRpy) /* Return to job default */
RCVMSG MSGDTA(&MSGDTA) MSGDTALEN(&MSGDTALEN) MSGID(&MSGID)
If ( &MsgID = 'CPA2611') Then( Do )
ChgVar &VryOffErr '1'
ChgVar &WrkCfgSts '*YES'
Enddo

Looking at the job log where this error occurred:
9500 - VRYCFG CFGOBJ(EEPRD03B) CFGTYPE(*CTL) STATUS(*OFF)
Controller EEPRD03B cannot be varied off at this time. (C G)
? C
.. seems to show that CPA2611 is the only message that is issued when this error occurs. Yes? No? Could be better?

- Dan Bale

-----Original Message-----
From: MIDRANGE-L<midrange-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of Vern Hamberg via MIDRANGE-L
Sent: Monday, May 12, 2025 7:41 PM
To:midrange-l@xxxxxxxxxxxxxxxxxx
Cc: Vern Hamberg<vhamberg@xxxxxxxxxxxxxxx>
Subject: Re: VRYCFG CFGTYPE(*CTL) STATUS(*OFF) results in CPA2611 (C G)

I found the link, I'd posted it in these lists in June, 2010. Here you go -

https://www.ibm.com/support/pages/receiving-messages-joblog-after-program-callstack

*Regards*

*Vern Hamberg*

IBM Champion 2025<cid:part1.nsQ0Zv00.7ltfoTUG@centurylink.net> CAAC (COMMON Americas Advisory Council) IBM Influencer 2023

On 5/12/2025 6:10 PM, Vern Hamberg via MIDRANGE-L wrote:
Hi Dan

There is a technique that has been around forever to retrieve all
messages in a span of time, some of them are not in the joblog. IBM
has a link, that I don't remember. But the idea is to send a dummy
message just before the actions you want to check and retrieve what is
called the MSGKEY. When the actions are done, send another dummy
message and retrieve its MSGKEY. Then loop from first MSGKEY to second
MSGKEY and use RCVMSG with the MSGKEY parameter set - have a monitor
or MONMSG, since some MSGKEY messages will be discarded. Get primary
message and second-level as needed.

*Regards*

*Vern Hamberg*

IBM Champion 2025<cid:part1.gV1Pi0gb.Sz2859u0@centurylink.net> CAAC
(COMMON Americas Advisory Council) IBM Influencer 2023

On 5/12/2025 5:15 PM, Dan Bale wrote:
I have a CL program that varies off anywhere between 10 and 24
controllers.
VRYCFG CFGOBJ(ABC) CFGTYPE(*CTL) STATUS(*OFF) sometimes results in:
Message ID . . . . . . : CPA2611 Severity . . . . . . : 99
Message . . . . : Controller ABC cannot be varied off at this
time. (C G)
Cause . . . . . : There are jobs in the network that are currently
using
controller ABC.
Recovery . . . : Use the Work with Configuration Status
(WRKCFGSTS) command
to determine which jobs are associated with controller ABC. For
information about jobs associated with controller ABC, use the
Display
APPN Information (DSPAPPNINF) command or the Work with APPN Status
(WRKAPPNSTS) command.
Type G to vary off controller ABC with active jobs.
Type C to either wait for the jobs to complete before you try
to vary the
controller off again or end the jobs yourself and vary off the
controller.
This message can't be monitored and there are no other messages
issued with this. Is there a way to handle this programmatically?
Is there an alternative interface to VRYCFG that handles this?
*** CONFIDENTIALITY NOTICE: The information contained in this communication may be confidential, and is intended only for the use of the recipients named above. If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender. ***

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.