VARY TERM command

VARY TERM command using name or name pair:

Read syntax diagramSkip visual syntax diagramVARY NET ,TERM,LU1=lu_name,LU2=lu_name,LU2=lu_name,LU1=lu_name,PLU=plu_name,SLU=slu_name,SLU=slu_name,PLU=plu_name,TYPE=UNCOND,TYPE=CONDFORCEUNCOND,SCOPE=ACT,SCOPE=ACTALLQ,NOTIFY=YES,NOTIFY=NOYES

VARY TERM command using session ID:

Read syntax diagramSkip visual syntax diagramVARY NET ,TERM,SID= session_id,TYPE=UNCOND,TYPE=CONDFORCEUNCOND,SCOPE=ACT,SCOPE=ACTALLQAPPN,NOTIFY=YES,NOTIFY=NOYES

Abbreviations

Operand Abbreviation
VARY V

Purpose

The VARY TERM command may be used to terminate a session or group of sessions. The command can identify one or several of the following sessions for termination:
  • A single session by its session identifier (SID)
  • All of the sessions for which a specified logical unit is the primary session partner (PLU)
  • All of the sessions for which a specified logical unit is the secondary session partner (SLU)
  • All of the sessions between a specified pair of logical units having a specified primary/secondary relationship as session partners (PLU and SLU)
  • All of the sessions for which a specified logical unit is a session partner, without regard to its primary or secondary status (LU1)
  • All of the sessions between a specified pair of logical units, without regard to their primary/secondary relationship as session partners (LU1 and LU2)
The VARY TERM command may be used to terminate an APPN search. The command can identify one search for termination:
  • A single search by its session identifier (SID)

You can use the DISPLAY SESSIONS command to display the sessions that are to be terminated with this command. If a session is displayed with an A- session state, you may be able to terminate the session at this host by issuing the VARY TERM command with the SCOPE=APPN operand coded. If this is unsuccessful, issue VARY TERM from one of the session endpoints.

VTAM® overrides persistence and terminates the application and sessions normally.

Issuing a VARY TERM command to terminate the CP-CP session with an adjacent node might cause later session establishment requests to fail. To resolve the problem, reactivate the CP-CP session or else reactivate the link with CPCP=NO so that it will no longer be used in directed search routing.

Operands

LU1=lu_name
Identifies the logical unit whose sessions are to be terminated. If you also specify the LU2 operand, only sessions involving both specified logical units are terminated. LU1 can be either the primary LU or the secondary LU.

lu_name can be a network-qualified name. If the name is network-qualified, it is considered to be the real name of the resource. If a non-network-qualified name is specified, the name can be an ACB name, an alias name, or the real name of a local resource.

If a cross-network CDRSC is to be specified on the LU1 operand and the CDRSC is defined using NQNMODE=NQNAME (either by definition or start option), it must be specified as a network-qualified name.

LU2=lu_name
Identifies the logical unit whose sessions are to be terminated. If you also specify the LU1 operand, only sessions involving both specified logical units are terminated. LU2 can be either the primary LU or the secondary LU.

lu_name can be a network-qualified name. If the name is network-qualified, it is considered to be the real name of the resource.

If a cross-network CDRSC is to be specified on the LU2 operand and the CDRSC is defined using NQNMODE=NQNAME (either by definition or start option), it must be specified as a network-qualified name.

NOTIFY
Specifies whether VTAM is to send a notification message to the operator when all affected sessions have ended.
NOTIFY=YES
Sends a notification message to the operator when all affected sessions have ended.
NOTIFY=NO
Does not send a message when all affected sessions have ended.
Note: For SCOPE=APPN search request termination, the NOTIFY operand is ignored.
PLU=plu_name
Identifies a primary logical unit. All sessions in which this logical unit functions as the primary session partner are terminated. If you also specify the SLU operand, only sessions involving both specified logical units in the specified primary/secondary relationship are terminated.

The value for plu_name can be a network-qualified name. If the name is network-qualified, it is considered to be the real name of the resource. If a network-qualified name is not specified, the default network identifier will be from the network where the command was issued.

If a cross-network CDRSC is to be specified on the PLU operand and the CDRSC is defined using NQNMODE=NQNAME (either by definition or start option), it must be specified as a network-qualified name.

SCOPE
Specifies the scope of the command.
SCOPE=ACT
Terminates only active sessions.

Note that the termination of an active session between a device-type logical unit and its controlling primary LU terminates the session (unless the session is terminated using TYPE=FORCE) but does not alter the basic controller relationship between them.

Deactivation and reactivation of the logical unit (including error recovery procedures), or use of the logical unit by another primary LU, results in the re-establishment of the logical unit's session with its controlling application program. If this is not the case, the controller session can be reestablished with a VARY LOGON command or by a specific session request from the primary LU.

SCOPE=ALL
Terminates all sessions, whether active or queued.
SCOPE=APPN
Terminates APPN searches. SCOPE=APPN can be used to terminate APPN search requests that otherwise could not be terminated using another variation of the VARY TERM command. The SID=operand is required when SCOPE=APPN is specified.

Use the DISPLAY SRCHINFO,LIST=ALL command to determine the session identifier of the search to be terminated.

SCOPE=Q
Terminates only queued sessions.

Note that the termination of a queued session between a device-type logical unit and its controlling primary LU does not alter the basic controller relationship between them.

SID=sessionid
Identifies the VTAM session or search to terminate. You can display the session ID by issuing the DISPLAY ID=resource,SCOPE=ALL command. The application program can be in either this domain (application program minor node) or another domain (CDRSC minor node). For SCOPE=APPN search request termination, you can display the session ID by issuing the DISPLAY SRCHINFO,LIST=ALL command. The session ID must be a valid hex number.
SLU=slu_name
Identifies a secondary logical unit. All sessions in which this logical unit functions as the secondary session partner are terminated. If you specify the PLU operand, only sessions involving both specified logical units in the specified primary/secondary relationship are terminated.

slu_name can be a network-qualified name. If the name is network-qualified, it is considered to be the real name of the resource.

If a cross-network CDRSC is to be specified on the SLU operand and the CDRSC is defined using NQNMODE=NQNAME (either by definition or start option), it must be specified as a network-qualified name.

TYPE
Specifies the type of session termination to be performed. If this command applies to queued sessions, they are terminated. This command will terminate only the primary session between the PLU and SLU; the backup session will not terminate.
Note:
  1. To avoid redriving the session for an automatic logon relationship, issue VARY TERM,TYPE=COND, or VARY TERM,TYPE=UNCOND.
  2. For a phantom session (an active session for which no SIB exists in this host), issue V NET,TERM,TYPE=UNCOND or V NET,TERM,TYPE=FORCE to terminate the session.
  3. If the VARY TERM command is issued in the SLU's host after takeover has occurred and the PLU for the session is in another host, the session might terminate properly. In that case, the VARY TERM command should be issued from the host where the PLU is.
  4. For a CP-CP session, TYPE=COND or UNCOND is converted by VTAM to TYPE=FORCE. The session will not be automatically re-established even if other CP-CP session-capable connections are subsequently activated. If you want to reactivate the session, issue a VARY ACT,ID=adjacent_cp,IDTYPE=CP command.
  5. For a CPSVRMGR session between a DLUR and a DLUS, TYPE=COND or UNCOND is converted to FORCE. If the DLUR allows ANS=CONTINUE, VTAM performs GIVEBACK for PUs supported by the DLUR, and current LU-LU sessions are not disrupted because the LUs become shadow resources.
  6. For SCOPE=APPN search request termination, the TYPE operand is ignored.
TYPE=COND
Specifies conditional termination.
Note: This command is rejected if the termination request is for a session with an unknown partner.

If this command applies to active sessions, they might be disrupted. PLUs involved in such sessions are notified of the operator's request for termination and can terminate the session.

If the PLU is an independent LU, the session remains active because independent LUs cannot perform orderly termination. If the session remains active, it is marked session end pending in each SSCP that knows of the termination request.

TYPE=FORCE
Specifies forced termination. If this command applies to active sessions, they are disrupted, and application programs involved in such sessions are notified of the disruption.

If a controlling relationship is set up for the logical unit, the session redrives because the termination was of an abnormal type.

TYPE=UNCOND
Specifies unconditional termination.

If this command applies to active sessions, they are disrupted. PLUs involved in such sessions are notified of the disruption.