Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

EXPORT-PUBSET

&pagelevel(3)&pagelevel

Export previously imported pubset

Component:

BS2000

Functional area:

Pubset and MRSCAT management

Domain:

MULTI-CATALOG-AND-PUBSET-MGMT

Privileges:

TSOS                                                                                                         
OPERATING

Routing code:

R

Function

The EXPORT-PUBSET command enables systems support personnel to remove a pubset as a resource from the local system. In a shared pubset network based on HIPLEX MSCF, a choice can be made as to whether exporting the shared pubset on the master system also entails exporting it on the slave systems, or whether the master function should pass to one of the slave systems.
Under control of the calling task, the command generates its own (new) task. This task performs EXPORT processing asynchronously to the calling task.
Successful generation of the EXPORT task and its messages are logged at the operator terminal.

During the export phase, the number of tasks that are still using the pubset is output. The TSN of the tasks involved can be determined using the SHOW-PUBSET-OCCUPATION command (and also the SHOW-PUBSET-PARAMETERS command) and used to force the tasks to terminate their activities.
The user catalog (SYSSRPM file) is closed. The information currently stored in the main memory regarding user IDs and disk storage occupancy is transferred. If this information cannot be transferred, reconstruction of the F5 label is initiated the next time the IMPORT-PUBSET command is issued.

The home pubset may not be exported using this command. The home pubset is exported automatically at system termination. 

Format

EXPORT-PUBSET

PUBSET = <cat-id 1..4>

,USE = *STD / *BY-REMOTE

,SHARER-TYPE = *STD / *SLAVE / *MASTER(...)


*MASTER(...)



|

MASTER-CHANGE = *NO / *YES

,TERMINATE-JOBS = *NO / YES

,MONJV = *NONE / <filename 1..54 without-gen-vers>

,JV-PASSWORD = *NONE / <c-string 1..4> / <x-string 1..8> / <integer -2147483639..2147483639>

Operands

PUBSET = <cat-id 1..4>
Catalog ID of the pubset to be exported.

USE = *STD / *BY-REMOTE
Specifies the status that the pubset being exported has to have.

USE = *STD
The pubset cannot be exported unless it is in “imported” or “remote imported” status.
If the local system has imported the pubset as master in a shared pubset network, then exporting it with the setting “MASTER-CHANGE=*NO” causes all slave systems to export it as well.

USE =*BY-REMOTE
The pubset cannot be exported unless it is in “remote-imported” status (i.e., only catalog accesses are possible).

SHARER-TYPE = *STD / *SLAVE / *MASTER(...)
Specifies which type of sharer as defined on pubset import will be accepted on pubset export.

SHARER-TYPE = *STD
The pubset will be exported regardless of sharer type.

SHARER-TYPE = *SLAVE
The pubset will be exported only if the local system imported the pubset as a slave sharer.

SHARER-TYPE = *MASTER(...)
The pubset will be exported only if the local system is a temporary owner of the pubset (master).

MASTER-CHANGE = *NO
Exporting the pubset implies a request to all slave sharers to export the pubset as well.

MASTER-CHANGE = *YES
An automatic change of master is to be initiated. The system defined as the backup master is to take over the role of master. The slave sharers are not forced to export the pubset. If no backup master is defined, or if the system defined as backup master is not active, pubset export is rejected.

TERMINATE-JOBS = *NO / *YES
Terminates the tasks that are using the pubset or waits until their allocations are cleared.

TERMINATE-JOBS = *NO
The pubset is made inaccessible. If the pubset is still allocated when this command is entered, the command does not take effect until all active allocations are cleared. New allocations are rejected.

TERMINATE-JOBS = *YES
Export processing cancels all tasks that are using the pubset. Note however that system tasks which are using the pubset cannot be terminated. That means that the system administration must ensure that all such allocations are cleared before EXPORT-PUBSET is called. Otherwise, export processing cannot be completed.
Processing is continued once all allocations are cleared. This must be preceded by an EXPORT-PUBSET command with TERMINATE-JOBS=NO. The wait state of an export job previously initiated with the TERMINATE-JOBS=NO operand is also canceled once all allocations have been cleared.

MONJV = *NONE / <filename 1..54 without-gen-vers>
Specifies whether a monitoring job variable is set. This operand should only be specified if the JV software product is used. The job variable is set to the following values:

$E

during export processing

$T

after successful completion of export processing

$A

if export processing was terminated with /CANCEL-PUBSET-EXPORT or because of an error.

The job variable must already be cataloged, otherwise it is not set. However, EXPORT processing is continued even if no job variables have been defined.

JV-PASSWORD = *NONE / <c-string 1..4> / <x-string 1..8> /<integer -2147483639..2147483639>
Password of the monitoring job variable.
The operand has the following special characteristics:

  • The password entered is not logged.

  • The input field is automatically blanked out in the guided dialog.

  • In unguided dialog and foreground procedures, the entry *SECRET or ^, SDF provides a blanked out input field for inputting the password. 

Return codes

(SC2)

SC1

Maincode

Meaning


0

CMD0001

No error

1

0

DMS0355

Same export already active

1

0

DMS0364

Pubset currently unavailable


1

CMD0202

Syntax error


32

DMS035C

Invalid operands


32

DMS0363

MRSCAT access error


64

DMS035C

IMPORT-PUBSET required


64

DMS0360

No authorization for command


64

DMS0366

Export attempt for home pubset


64

DMS036D

Invalid operand sequence


130

DMS0351

Other import/export task active


130

DMS035C

Maximum number of tasks reached


130

DMS0362

Class 4 memory error

Notes

During system termination, all imported pubsets are always exported, in the following order:

  1. During termination of HIPLEX MSCF, all shared imported pubsets are exported. A pubset imported as master is imported with the MASTER-CHANGE option set to *YES.

  2. Export all nonshared imported pubsets (except the home pubset):

    • EXPORT-PUBSET with TERMINATE-JOBS=*YES

    • wait until all pubsets have been exported (maximum approx. 1 minute)

    • FORCE-PUBSET-EXPORT for the pubsets that have not yet been exported

    • wait until all pubsets have been exported (maximum 1 minute)

  3. Export the home pubset:

    • EXPORT-PUBSET with the TERMINATE-JOBS=*YES

    • wait until the pubset has been exported (maximum 1 minute)

    • FORCE-PUBSET-EXPORT if the home pubset has not yet been exported

    • wait until the home pubset has been exported (maximum 1 minute)

The generated task executes in 2 phases:

Phase 1: Wait until all files of the pubset are closed.

This state only occurs if, in addition to the open system files (e.g. the user catalog, the guards catalog, the syntax file or the message file), other files of this pubset are open. This also implicitly involves the private files that are addressed via this pubset.
If only the system files whose associated components are informed by the export processing (such as the user administration or the guards administration) are opened, the wait state does not occur. The system files are open for each imported pubset and are not closed until the pubset is actually exported. If the wait state occurs, the number of tasks that are still using the pubset is output. The tasks involved can be displayed by means of the SHOW-PUBSET-OCCUPATION command (and also the SHOW-PUBSET-PARAMETERS command) and be forced to terminate their activities. By default, the wait state is canceled once all files (except the system files) are closed and Phase 2, the export phase proper, is initiated. In addition, the following events may cause the wait state to be canceled:

  • CANCEL-PUBSET-EXPORT command
    The wait state is canceled immediately. The EXPORT task terminates with an error message and the pubset remains available.

  • EXPORT-PUBSET command with the TERMINATE-JOBS=*YES operand
    An attempt is made to terminate all jobs that are still using the pubset. Once all allocations are cleared, the wait state is canceled and the second phase - the export phase - is initiated. The EXPORT task acknowledges the command.

  • FORCE-PUBSET-EXPORT command
    The wait state is canceled. The export task acknowledges the command and Phase 2 - the export phase - is initiated, even though not all the files of this pubset are closed. 

Phase 2: Export pubset

The pubset is made inaccessible. SPOOL is informed and all spoolout jobs whose files to be output are cataloged on the pubset involved are moved from TYPE5/AC to TYPE5/KP. The system files are closed and all resources are released.

Although wait states may occur during this phase, they are limited to approximately 10 minutes. The FORCE-PUBSET-EXPORT command reduces the wait state to 1 minute.

If an export job, with options for terminating occupying tasks or waiting for their allocations to be cleared, is issued at the master processor in shared pubset mode in a multiprocessor network, it is also effective at all the slave processors in the network. FORCE-PUBSET-EXPORT commands, however, are only effective at the local processor, i.e. they are not passed on to all the slave processors in the network.


If a shared imported pubset is exported at the master without a master change, the master notifies the slaves that the pubset must be exported and waits for them to finish (i.e. phases 1 and 2 run at the slave). Only then does the master also start with phase 1.