DB2 10.5 for Linux, UNIX, and Windows

db2idrop - Remove instance command

Removes a DB2® instance that was created by db2icrt.

You can only drop instances that are listed by the db2ilist command for the same DB2 copy where you are issuing the db2idrop command from. You can also use the db2idrop command to drop a DB2 pureScale® instance.

On Linux and UNIX operating systems, this utility is located in the DB2DIR/instance directory, where DB2DIR represents the installation location where the current version of the DB2 database system is installed. On Windows operating systems, this utility is located under the DB2PATH\bin directory where DB2PATH is the location where the DB2 copy is installed.

Note: A non-root-installed DB2 instance, on Linux and UNIX operating systems, cannot be dropped using this command. The only option is to uninstall the non-root DB2 copy. See the following Usage notes section for more details.

Authorization

Root user or non root user authority is required on Linux and UNIX operating systems. Local Administrator authority is required on Windows operating systems.

Command syntax

For root installation on Linux and UNIX operating systems
Read syntax diagramSkip visual syntax diagram
>>-db2idrop--+-----+--+-----+----| DB2 pureScale options |------>
             '- -d-'  +- -h-+                                  
                      '- -?-'                                  

>----| Outside Of DB2 pureScale options |----InstName----------><

DB2 pureScale options

|--+-----+------------------------------------------------------|
   '- -g-'   

Outside Of DB2 pureScale options

|--+-----+------------------------------------------------------|
   '- -f-'   

For a non-root thin server instance on Linux and AIX operating systems
Read syntax diagramSkip visual syntax diagram
>>-db2idrop--+-----+--+-----+----------------------------------><
             '- -d-'  +- -h-+   
                      '- -?-'   

For root installation on Windows operating systems
Read syntax diagramSkip visual syntax diagram
>>-db2idrop--InstName--+-----+--+-----+------------------------><
                       '- -f-'  '- -h-'   

Command parameters

For root installation on Linux and UNIX operating systems
-d
Enters debug mode, for use by DB2 database support.
-h | -?
Displays the usage information.
-g
This parameter is required when db2idrop is used with a DB2 pureScale instance. Specifies that you want to drop the DB2 pureScale instance on all hosts. This parameter requires all DB2 members and all cluster caching facilities are stopped on all the hosts in the DB2 pureScale instance. This option will be ignored for dropping any other instance type
-f
This parameter is deprecated.

Specifies the force applications flag. If this flag is specified all the applications using the instance will be forced to terminate. This parameter is not supported on a DB2 pureScale environment.

InstName
Specifies the name of the instance.
For a non-root thin server instance on Linux and AIX operating systems
-d
Enters debug mode, for use by DB2 database support.
-h | -?
Displays the usage information.
For root installation on Windows operating systems
-f
Specifies the force applications flag. If this flag is specified all the applications using the instance will be forced to terminate.
-h
Displays usage information.
InstName
Specifies the name of the instance.

Example

If you created db2inst1 on a Linux or UNIX operating system by issuing the following command:
/opt/IBM/db2/copy1/instance/db2icrt -u db2fenc1 db2inst1
To drop db2inst1, you must run the following command:
/opt/IBM/db2/copy1/instance/db2idrop db2inst1

Usage notes