-START DB2 command (Db2)

The Db2 command START DB2 initializes the Db2 subsystem. When the operation is complete, the Db2 subsystem is active and available to TSO applications and to other subsystems (for example, IMS and CICS®).

The effect of restarting the system can be controlled by a conditional restart control record, which you create by using the DSNJU003 (change log inventory) utility. For more details about the effects, see Usage notes.

Important: Start of changeDo not attempt to start Db2 at a code level that is lower than the catalog level or highest ever activated function level. For more information, see Function levels and related levels in Db2 12.End of change

Abbreviation: -STA DB2

Environment

This command can be issued only from a z/OS® console. The name of the Db2 subsystem is determined by the command prefix. For example, -START indicates that the Db2 subsystem to be started is the one with '-' as the command prefix.

The command is rejected if the Db2 subsystem is already active. The restart recovery status of Db2 resources is determined from the prior Db2 shutdown status.

Data sharing scope: Member

Authorization

None is required. However, the command can be executed only from a z/OS console with the START command capability.

Syntax

Read syntax diagramSkip visual syntax diagramSTART DB2PARM(module name)DECP(DSNCDECPdecp-name)ACCESS(*MAINT)LIGHT(NOYESNOINDOUBTSCASTOUT)MSTR( jcl-substitution)DBM1( jcl-substitution)DIST( jcl-substitution)

Option descriptions

None of the following options are required.
PARM ( module-name )
Specifies the load module that contains the Db2 subsystem parameters.

The default is the name of the parameter module that was specified on panel DSNTIPO when the installation CLIST was run. The default can also be changed if you update ZPARM(default-module-name) in the ssnmMSTR Db2 subsystem startup procedure.

DECP
Specifies the name of the load module that contains Db2 application parameter defaults.

decp-name is the name of a module that is provided by the installation. The default name is DSNHDECP. If the specified module is not found or cannot be loaded, an error is issued, and the Db2 subsystem does not start.

ACCESS
Specifies whether access to Db2 is to be general or restricted.
Abbreviation: ACC
( * )
Makes access general; all authorized users can connect to Db2.

The default is ACCESS( * ) .

(MAINT)
Prohibits access to any authorization IDs other than installation SYSADM, installation SYSOPR, and SECADM.

For data sharing, ACCESS(MAINT) restricts access on only the Db2 member on which you execute this command. Other members of the data sharing group are unaffected.

LIGHT
Specifies whether a light restart is to be performed in a data sharing environment.
(NO)
A light restart is not performed.
(YES)
Specifies that a light restart is to be performed. Db2 takes these actions:
  • Starts with reduced storage.
  • Waits for resolution of indoubt units of recovery.
  • Frees retained locks. Page set P-locks in IX or SIX mode are not freed.
  • Terminates normally.
(NOINDOUBTS)
Specifies that Db2, during a light restart, does not wait for indoubt units of recovery to resolve before it terminates.
(CASTOUT)
Specifies that a light restart is to be performed with castout processing. Db2 takes these actions:
  • Starts with reduced storage.
  • Waits for resolution of indoubt units of recovery.
  • Performs castout processing.
  • Frees retained locks. Page set P-locks in IX or SIX mode are freed, if possible.
  • Terminates normally.

If a light restart does not resolve all indoubt and postponed-abort units of recovery, Db2 does not release the associated page set P-locks that are in IX or SIX mode. One reason for unresolved postponed-abort units of recovery is that the LBACKOUT subsystem parameter is set to LIGHT or LIGHTAUTO.

MSTR ( jcl-substitution )
Specifies parameters and values to be substituted in the EXEC statement of the JCL that executes the startup procedure for the system services address space (ssnmMSTR), where jcl-substitution is one or more character strings of the form keyword=value, enclosed between apostrophes. If you use more than one character string, separate each string with a comma and enclose the entire list between a single pair of apostrophes. For the list of supported keywords, see Starting a system task from a console.
Restriction: Start of changeDb2 address spaces, and all connected address spaces, cannot be started with the REUSASID=YES keyword to use the z/OS reusable address space ID (ASID) capability.End of change
Tip: You can omit the MSTR, DBM1, and DIST keywords, or omit any jcl-substitution keywords, to use the values specified in the address-space startup procedures, which are created when you run job DSNTIJMA during the installation process.
DBM1 ( jcl-substitution )
Specifies parameters and values to be substituted in the EXEC statement of the JCL that executes the startup procedure for the database services address space (ssnmDBM1), where jcl-substitution is as described for MSTR.
DIST ( jcl-substitution )
Specifies parameters and values to be substituted in the EXEC statement of the JCL that executes the startup procedure for the DDF address space (ssnmDIST), where jcl-substitution is as described for MSTR.

Usage notes

Command prefix
If your installation has more than one Db2 subsystem, you must define more than one command prefix.
Conditional restart
A conditional restart control record can prevent a complete restart and specify current status rebuild only. In that case, the following actions occur during restart:
  • Log records are processed to the extent that is determined by the conditional restart control record.
  • The following values are displayed:
    • The relative byte address (RBA) of the start of the active log
    • The RBA of the checkpoint record
    • The status counts for units of recovery
    • The display table for restart unit of work elements
  • The restart operation terminates with an abend.
Light restart with ARM

To enable a light restart in an ARM environment, you must code an ARM policy for Db2 and IRLM.

The following example shows an ARM policy for Db2, where the element name is the Db2 data sharing group name and member name concatenated. For example, DSNDB0GDB1G.
ELEMENT(
elementname
)

   RESTART_METHOD(SYSTERM,STC,'
cmdprfx
 STA DB2,LIGHT(YES)')
The following example shows an ARM policy for IRLM, where the element name is the IRLM group name and the ID concatenated. For example, DXRDB0GDJ1G001.
ELEMENT(
elementname
)

   RESTART_METHOD(SYSTERM,STC,'
cmdprfx
 S 
irlmproc
')

The element name that Db2 uses is the Db2 data sharing group name and member name concatenated. For example, DSNDB0GDB1G.F

Endless wait during start
The start operation might begin and fail to complete, if the system services address space (ssnmMSTR) starts and the database services address space (ssnmDBM1) cannot start. If a seemingly endless wait occurs, cancel the system services address space (ssnmMSTR) from the console, and check both startup procedures for JCL errors.
Starting members of a data sharing group

To start members of a data sharing group, you must enter a START DB2 command for each subsystem in the group. If it is the first startup of the group, you must start the originating member (the first Db2 that was installed) first.

Start of changeStarting data sharing members with light restartEnd of change
Start of changeWhen starting data sharing members with light restart, start one data sharing member a time.End of change
Start of changeRestarting data sharing members after light restartEnd of change
Start of changeRestart any Db2 data sharing member that goes through restart light again with a regular start. Otherwise, certain lock avoidance optimizations can remain disabled for all data sharing members. For more information about the optimizations that might become disabled, see Global commit LRSN enhancement in Db2 12 for z/OS Performance Topics (IBM Redbooks).End of change

Examples

Example 1
Start the Db2 subsystem.
-START DB2
Example 2
Start the Db2 subsystem, and provide a new value for the REGION parameter in the startup procedure for the system services address space (ssnmMSTR).
-START DB2 MSTR('REGION=6000K')
Example 3
Start the Db2 subsystem. Assuming that the EXEC statement of the JCL that executes the startup procedure for the system services address space (ssnmMSTR) uses the symbol RGN, provide a value for that symbol.
-START DB2 MSTR('RGN=6000K')
Example 4
Db2 subsystems DB1G and DB2G are members of a data sharing group. Both were installed with a command prefix scope of STARTED. Start DB1G and DB2G by routing the appropriate commands to the z/OS system on which they are to be started, MVS1 and MVS2.
ROUTE MVS1,-DB1G START DB2
ROUTE MVS2,-DB2G START DB2
Example 5
Start the Db2 subsystem, then provide the parameter module and a value for the DECP option. Enter either DSNCDECP or another decp-name
 -START DB2 PARM(VA1AZNS) DECP(DSNHDVA1)