SHRLEVEL
The SHRLEVEL option specifies the level of access to the target table space or index space to allow to concurrently operating Db2 applications and utilities. You can specify no access, read-only access, or read-write access. If you do not specify this option,
BMC AMI Copy
allows read-only access to the target table space during the copy process.
SHRLEVEL syntax diagram
If more than one copy job is running concurrently on the same space, all copies must have the same value for the SHRLEVEL option.
For more information, see Using-the-SHRLEVEL-option. Also, Db2-commands-issued-by-BMC-AMI-Copy-for-read-and-write-databases describes space status changes made by BMC AMI Copy for various scenarios that use the SHRLEVEL option.
SHRLEVEL REFERENCE
SHRLEVEL REFERENCE is the default and allows read-only access by other programs to the target space during the copy process. Db2 applications and utilities can read the space, but they cannot update it.
SHRLEVEL NONE
Use SHRLEVEL NONE to tell BMC AMI Copy to stop all access by Db2 applications and utilities to the space during the copy process.
When you specify SHRLEVEL NONE, BMC AMI Copy can make copies of spaces in REORP status.
SHRLEVEL CHANGE
Use SHRLEVEL CHANGE to tell BMC AMI Copy to maintain the initial status of the space. When you specify SHRLEVEL CHANGE, you might also want to specify QUIESCE AFTER to establish a good recovery point.
When you specify SHRLEVEL CHANGE, BMC AMI Copy can make copies of spaces in REORP status.
Normally, you would specify the RESETMOD NO option or set the RESETMOD installation option to NO for a TABLESPACE specification when you specify SHRLEVEL CHANGE. If you specify RESETMOD YES with SHRLEVEL CHANGE, BMC AMI Copy passes the COPY command to the IBM Db2 COPY utility for processing if the SLCHGRESET option is NO. If SLCHGRESET is YES, BMC AMI Copy will make the copy and reset the modification indicators natively. SLCHGRESET YES requires XBM. See Resetting-modified-page-indicators-RESETMOD for more information about the RESETMOD installation option.
SHRLEVEL CHANGE is not allowed for a table space that is defined as NOT LOGGED.
Important: For additional job requirements, see Copy-registration-in-a-data-sharing-environment-for-SHRLEVEL-CHANGE.
SHRLEVEL CHANGE CONSISTENT
The SHRLEVEL CHANGE CONSISTENT YES option provides an efficient way to make consistent copies of Db2 table spaces and indexes without having to quiesce or cause any other outage to the spaces being copied.
Value | Description |
---|---|
YES | If you specify YES, BMC AMI Copy makes a consistent copy. You may include a WORKID with SHRLEVEL CHANGE CONSISTENT YES. Log Master uses the WORKID as a unique identifier for a unit of work. Use a WORKID if you plan to run the Log Master LOGSCAN statement to capture the changes after the consistent copy is made. |
NO | If you specify NO, BMC AMI Copy does not make a consistent copy. CONSISTENT NO is the default. |
SHRLEVEL ANY
Use SHRLEVEL ANY to tell BMC AMI Copy to attempt to use SHRLEVEL CHANGE unless it encounters conditions that require more restrictive access. When a more restrictive access than SHRLEVEL CHANGE is required, BMC AMI Copy uses SHRLEVEL REFERENCE.
SHRLEVEL CONCURRENT
Use SHRLEVEL CONCURRENT to utilize the BMC AMI Copy Snapshot Feature. SHRLEVEL CONCURRENT allows BMC AMI Copy to make consistent copies of the specified spaces while updates are in progress. SHRLEVEL CONCURRENT copies that complete without error are registered as SHRLEVEL REFERENCE.
For the description of an OPTIONS command keyword that you might want to specify when making Snapshot Copies, see XBMRSTRT .
When you specify SHRLEVEL CONCURRENT, you can also specify:
What action BMC AMI Copy should take in the event a consistent point cannot be obtained or maintained during the copy process
Use the keyword REQUIRED or PREFERRED following SHRLEVEL CONCURRENT to indicate the action required. Note that if you specify ON ERROR ... SKIP with SHRLEVEL CONCURRENT PREFERRED or with SHRLEVEL CONCURRENT REQUIRED and a skippable error occurs, skip processing takes precedence.
An XBM subsystem ID to be used by BMC AMI Copy when you want to override the setting of the XBMID installation option
Use the XBMID keyword after REQUIRED or PREFERRED to specify a new XBM subsystem ID.
SHRLEVEL CONCURRENT REQUIRED
Specify REQUIRED to tell BMC AMI Copy to terminate the copy with RC=12 if a consistent point cannot be obtained or maintained. One of the reasons a RC=12 is returned is if the initialization of the SNAPSHOT UPGRADE FEATURE or XBM fails.
Option | Description |
---|---|
INIT | The INIT option allows you to continue BMC AMI Copy processing or to halt it after completing XBM registration of SHRLEVEL CONCURRENT REQUIRED copies. |
Values of INIT
Value | Description |
---|---|
INIT CONTINUE | INIT CONTINUE is the default value and causes BMC AMI Copy to continue processing without halting. |
INIT PAUSE | INIT PAUSE applies to one SHRLEVEL CONCURRENT REQUIRED group. Only one occurrence of INIT PAUSE can appear in an BMC AMI Copy step. Other BMC AMI Copy statements can appear before and after the statement in which you specify INIT PAUSE. INIT PAUSE causes BMC AMI Copy to end after completing XBM registration of SHRLEVEL CONCURRENT REQUIRED copies. The job halts after all INIT processing for a group of table spaces completes. At that time, all of the affected table spaces are under control of XBM. INIT PAUSE has the following limitations:
You must restart BMC AMI Copy with NEW/RESTART or RESTART after the interruption in processing caused by INIT PAUSE. For more information, see Restart parameter (restartParm). |
SHRLEVEL CONCURRENT PREFERRED
PREFERRED is the default value and tells BMC AMI Copy to continue the copy as a SHRLEVEL CHANGE copy if:
- A consistent point cannot be obtained or maintained, or
- Initialization of the SNAPSHOT UPGRADE FEATURE or XBM fails.
Also, consider the following information when you use this option:
If you specify SHRLEVEL CONCURRENT PREFERRED and DSSNAP YES and the Instant Snapshot fails, the copy fails and does not continue as a SHRLEVEL CHANGE copy. (Also note that the specification of SHRLEVEL CONCURRENT PREFERRED and DSSNAP YES prevents the use of multitasking.)
However, when you specify DSSNAP AUTO with SHRLEVEL CONCURRENT PREFERRED, if the Instant Snapshot fails, BMC AMI Copy attempts a Snapshot Copy (SHRLEVEL CONCURRENT). Then, if the Snapshot Copy fails, BMC AMI Copy continues the copy as a SHRLEVEL CHANGE copy. See Making-Instant-Snapshot-copies for more information.
- If CHECKTSLEVEL 2 is specified with SHRLEVEL CONCURRENT PREFERRED and a consistent point cannot be obtained or maintained, the level of checking falls back to CHECKTSLEVEL 1.
If the BMC AMI Copy connection to XBM fails before or during the copy, SHRLEVEL CONCURRENT PREFERRED usage causes BMC AMI Copy to continue processing as if SHRLEVEL CHANGE QUIESCE BEFORE were specified. But if it finds no updates after the quiesce, BMC AMI Copy will register a SHRLEVEL REFERENCE copy.
Related topic