caspac

The caspac utility can be used to administer a PAC.
Attention: This feature is in Early Adopter Program (EAP) release status. We will continue the development of additional features and provide additional interfaces via patch updates and future releases. Please contact Micro Focus SupportLine if you require further clarification.
Restriction: This topic applies only when the Enterprise Server feature is enabled.

Syntax:

caspac -a{action}=object -s{store} -n{psorName}

Parameters:

-a
Specifies the action to perform and the object it will be performed on.
action
Specifies the action to perform and can take one of the following values:
Load
Loads and deploys a non CICS or JES object as soon as the caspac command is issued. The object is deployed into the PAC_LOADLIB folder of the region's workarea.
LoadCics
Loads an object ready to be deployed into CICS when you execute the CPMT NE command. The object is deployed into the PAC_LOADLIB_CICS folder of the region workarea.
LoadJes
Load an object and deploy it directly into the PAC_LOADLIB_JES folder of the region workarea
Delete
Deletes a loaded file from the SOR.
List
Lists the user programs that have been loaded into the SOR.
InitPac
Initializes the PAC ready for a cold start. This removes all the stores that had been created by a previous run for the specified PAC. This option is only applied if all the regions in the PAC specified are not active.
Status
Provides the current status for the PAC.
Dump
Creates a dump file of the stores that have been created for the specified PAC.
Restore
Restores a dump file into the specified SOR.
PacLog
Creates a log file for messages generated by the PAC using the specified SOR.
object
Specifies the object the action is to use and can take one of the following values depending on the action being taken:
  • DLL
  • Share Object
  • PAC Name
  • Dump File
  • PAC Log File
Note: The object name is case-sensitive.
-sstore
Specifies the store and its connection parameters to use. This is the scale-out repository type and connection parameters. For example:
redis,127.0.0.1:6741
-n{psorName}
Name of the PAC SOR. This is only required for Redis AUTH authentication requests or Redis SENTINEL. See Providing Credentials for Redis using Secrets for more information.

When using Redis AUTH you will need to create a secret in the vault facility for each PSOR that is used as a reference using the -n option.

Examples

  • The following example loads acct.dll into the SOR represented by the Redis server located at 127.0.0.1 on port 6741. The acct.dll can then be deployed to all active enterprise server instances in the PAC using the New Copy command:
    caspac -aLoadCics="c:\new files\acct.dll" -sredis,127.0.0.1:6741 -npsorName
  • The following example loads all files under c:\new files into the SOR represented by the Redis server located at 127.0.0.1 on port 6741. Because this is for JES, a new copy command is not required:
    caspac -aLoadJes="c:\new files\*.*" -sredis,127.0.0.1:6741 -npsorName
  • The following example loads all non CICS and JES files under c:\new files into the SOR represented by the Redis server located at 127.0.0.1 on port 6741:
    caspac -aLoad="c:\new files\*.*" -sredis,127.0.0.1:6741 -npsorName
  • The following example removes acct.dll from the SOR represented by the Redis server located at 127.0.0.1 on port 6741:
    caspac -aDelete=acct.dll -sredis,127.0.0.1:6741 -npsorName
  • The following example lists user programs that have been uploaded into the SOR:
    caspac -aList=* -sredis,127.0.0.1:6741 -npsorName
  • The following example initializes the PAC called MyPAC ready for a cold start. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aInitPac=MyPac -sredis,127.0.0.1:6741 -npsorName
  • The following example returns the status of the PAC called MyPAC. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aStatus=MyPAC -sredis,127.0.0.1:6741 -npsorName
  • The following example creates a dump of the PAC called MyPAC. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aDump=MyPAC -sredis,127.0.0.1:6741 -npsorName
  • The following example restores a PAC from a the CasPAC_127.0.0.1_06741.rdmp dump file. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aRestore=CasPAC_127.0.0.1_06741.rdmp -sredis,127.0.0.1:6741 -npsorName
  • The following example restores a PAC from a dump file that matches the use of the * wildcard. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aRestore=*.rdmp -sredis,127.0.0.1:6741 -npsorName
  • The following example writes a PAC log file to the folder and file specified. The PAC has a PSOR that uses a Redis server located at 127.0.0.1 on port 6741:
    caspac -aPacLog="c:\temp\PacLog.log" -sredis,127.0.0.1:6741 -npsorName