Removing Db2 database products using the db2_deinstall and doce_deinstall commands (Linux and UNIX)

This task provides steps for removing Db2 database products or Db2 database components using the db2_deinstall and doce_deinstall commands.

Before you begin

Before you remove Db2 database products from your system, ensure that you have performed all steps outlined in Uninstalling your Db2 database product (Linux and UNIX)

About this task

This task applies to Db2 database products that were installed with root user authority. To uninstall Db2 database products that were installed without root user authority, see Uninstalling non-root Db2 database products (Linux and UNIX).

The db2_deinstall command removes Db2 database products from your system.


Restrictions

  • You cannot remove Db2 database products using a native operating system utility, such as rpm or SMIT.
  • The doce_deinstall command is available only on Linux operating systems (Linux x32 and x64).

Procedure

To remove Db2 database products, features from a specific path:

  1. Log in with root user authority.
  2. Access the path where the Db2 database products are located. To locate the path of the Db2 database product to remove, see Listing Db2 database products installed on your system (Linux and UNIX).
  3. Run one of the following commands:
    • To remove a feature from an installed Db2 database product in the current location, run the db2_deinstall -F command from the DB2DIR/install directory.
    • To remove all installed Db2 database products in the current location, run the db2_deinstall -a command from the DB2DIR/install directory.
    • To remove a Db2 database product using a response file, run the db2_deinstall -r response_file command from the DB2DIR/install directory. You can use a sample response file to uninstall the product. For example, doce_deinstall -r db2un.rsp
    where DB2DIR is the location that you specified when you installed your Db2 database product.