Dropping a database partition from an instance (Windows)

On Windows, use the db2ndrop command to drop a database partition server from an instance that has no databases. If you drop a database partition server, its database partition number can be reused for a new database partition server.

About this task

Exercise caution when you drop database partition servers from an instance. If you drop the instance-owning database partition server zero (0) from the instance, the instance becomes unusable. If you want to drop the instance, use the db2idrop command.

Note: Do not use the db2ndrop command if the instance contains databases. Instead, use the STOP DBM DROP DBPARTITIONNUM command. This ensures that the database is correctly removed from the database partition. DO NOT EDIT the db2nodes.cfg file, since changing the file might cause inconsistencies in the partitioned database environment.

If you want to drop a database partition that is assigned the logical port 0 from a computer that is running multiple logical database partitions, you must drop all the other database partitions assigned to the other logical ports before you can drop the database partition assigned to logical port 0. Each database partition server must have a database partition assigned to logical port 0.

The command has the following parameters:
   db2ndrop /n:dbpartitionnum /i:instance_name
/n:dbpartitionnum
The unique database partition number (dbpartitionnum) to identify the database partition server. This is a required parameter. The number can be from zero (0) to 999 in ascending sequence. Recall that database partition zero (0) represents the instance-owning computer.
/i:instance_name
The instance name (instance_name). This is an optional parameter. If not given, the default is the current instance (set by the DB2INSTANCE registry variable).