DB2 Version 9.7 for Linux, UNIX, and Windows


Modifies individual entries in a specific database configuration file. A database configuration file resides on every database partition on which the database has been created.


This command updates all database partitions by default, except when DBPARTITIONNUM is specified to update only one database partition.


One of the following:

Required connection

Database. The database connection must be local to the instance containing the connected database.

Command syntax

Read syntax diagramSkip visual syntax diagram
           '-DB-------'  +-CONFIG--------+   



          V                                      |   


Command parameters

Some configuration parameters can be set to AUTOMATIC, allowing DB2® to automatically adjust these parameters to reflect the current resource requirements. For a list of configuration parameters that support the AUTOMATIC keyword, refer to the configuration parameters summary. If a value is specified along with the AUTOMATIC keyword, it might influence the automatic calculations. For specific details about this behavior, refer to the documentation for the configuration parameter.
Note: The appl_memory, logindexbuild, max_log and num_log_span database configuration parameters can only be set to AUTOMATIC using the command line processor.
Make the changes only in the configuration file, so that the changes take effect the next time you reactivate the database.
FOR database-alias
Specifies the alias of the database whose configuration is to be updated. Specifying the database alias is not required when a database connection has already been established. The database alias must be defined locally on the server. You can update the configuration file for another database residing under the same database instance. For example, if you are connected only to database db11, and issue update db config for alias db22 using .... immediate:
  • If there is no active connection on db22, the update will be successful because only the configuration file needs to be updated. A new connection (which will activate the database) will see the new change in memory.
  • If there are active connections on db22 from other applications, the update will work on disk but not in memory. You will receive a warning saying that the database needs to be restarted.
DBPARTITIONNUM db-partition-num
If a database configuration update is to be applied to a specific database partition, this parameter may be used. If this parameter is not provided, the update will take effect on all database partitions.
Make the changes immediately, while the database is running. IMMEDIATE is the default action. Since the ADMIN_CMD procedure requires a database connection, the changes will be effective immediately for any dynamically configurable parameters for the connected database.

This is a default clause when operating in the CLPPlus interface as well. IMMEDIATE need not be called when using CLPPlus processor.

Disables automatic tuning for the configuration parameter. The parameter is set to its current internal value and is no longer updated automatically.
USING config-keyword value
config-keyword specifies the database configuration parameter to be updated. value specifies the value to be assigned to the parameter.


Set the database configuration parameter sortheap to a value of 1000 on the database partition to which the application is currently connected to.

Usage notes

Command execution status is returned in the SQLCA resulting from the CALL statement.

The database-alias must be an alias name that is defined on the server.

The command affect all database partitions unless DBPARTITIONNUM is specified.

To view or print a list of the database configuration parameters, use the SYSIBMADM.DBCFG administration view.

To reset all the database configuration parameters to the recommended defaults, use the RESET DATABASE CONFIGURATION command using the ADMIN_CMD procedure.

To change a database configuration parameter, use the UPDATE DATABASE CONFIGURATION command through the ADMIN_CMD procedure. For example, to change the logging mode to "archival logging" on a single-partition database environment containing a database called ZELLMART, use:

CALL SYSPROC.ADMIN_CMD ('update db cfg for zellmart using logretain recovery')

To check that the logretain configuration parameter has changed, use:

To update a database configuration parameter on a specific database partition, you can:
  1. set the DB2NODE variable to a database partition number.
  2. connect to the database partition.
  3. update the database configuration parameters using UPDATE DATABASE CONFIGURATION command through the ADMIN_CMD procedure.
  4. disconnect from the database partition.
or you can use DBPARTITIONNUM. For example, to update the logging mode to only one specific partition (30) using DBPARTITIONNUM, use:
CALL SYSPROC.ADMIN_CMD ('update db cfg for zellmart dbpartitionnum 30 using
 logretain recovery')

For more information about DB2 configuration parameters and the values available for each type of database node, see the individual configuration parameter descriptions. The values of these parameters differ for each type of database node configured (server, client, or server with remote clients).

Not all parameters can be updated.

Some changes to the database configuration file become effective only after they are loaded into memory. All applications must disconnect from the database before this can occur. For more information on which parameters are configurable online and which ones are not, see summary list of configuration parameters.

If an error occurs, the database configuration file does not change. The database configuration file cannot be updated if the checksum is invalid. This might occur if the database configuration file is changed without using the appropriate command. If this happens, the database must be restored to reset the database configuration file.