Dropping a DB2 database

Normally, to drop a database in DB2, you run the following command:

>db2 drop db YourDb

If you run into errors trying to drop the database, you may need to recatalog the database. You can run the following series of commands:

>db2 uncatalog db YourDb
>db2 catalog database

Restart DB2.

Then run:

>db2 drop db YourDb