Dropping database partitions

You can drop a database partition that is not being used by any database and free the computer for other uses.

Before you begin

Verify that the database partition is not in use by issuing the DROP DBPARTITIONNUM VERIFY command or the sqledrpn API.
  • If you receive message SQL6034W (Database partition not used in any database), you can drop the database partition.
  • If you receive message SQL6035W (Database partition in use by database), use the REDISTRIBUTE DATABASE PARTITION GROUP command to redistribute the data from the database partition that you are dropping to other database partitions from the database alias.
Also ensure that all transactions for which this database partition was the coordinator have all committed or rolled back successfully. This might require doing crash recovery on other servers. For example, if you drop the coordinator partition, and another database partition participating in a transaction crashed before the coordinator partition was dropped, the crashed database partition will not be able to query the coordinator partition for the outcome of any indoubt transactions.

Procedure

To drop a database partition using the command line:

Issue the STOP DBM command with the DROP DBPARTITIONNUM parameter to drop the database partition.

After the command completes successfully, the system is stopped. Then start the database manager with the START DBM command.