Multiple Db2 copies on the same computer (Linux and UNIX)

Db2 products can be installed to an installation path of your choice. Db2 products can also be installed multiple times on a single machine. Each Db2 Copy can be at the same or different code levels.

Root installations of Db2 products can be installed to an installation path of your choice. Unless specified otherwise, the default installation paths are:
  • for the AIX® operating system /opt/IBM/db2/V11.5
  • for Linux® operating systems /opt/ibm/db2/V11.5
If you are using the Db2 Setup wizard and choose to install a new Db2 copy when the default installation path is already in use, the default path becomes:
  • for AIX /opt/IBM/db2/V11.5_##
  • for Linux /opt/ibm/db2/V11.5_##
where ## is a zero-prefixed sequential number in the range 01 to 99. The first occurrence of modifying the default path is _01. For example, a Db2 product is installed using the Db2 Setup wizard without specifying an installation path, and, the default installation path /opt/ibm/db2/V11.5 is already in use, the Db2 product will be installed in the new default path /opt/ibm/db2/V11.5_01.

If you install a Db2 copy using an installation method other than the Db2 Setup wizard, you must specify the installation path. Automatic sequential incrementation of the default path only occurs when the Db2 Setup wizard is used to install a Db2 copy. Regardless of the installation method, another full product cannot be installed in the path of another copy (such as /opt/ibm/db2/V11.5). A copy installed to a subdirectory of an existing copy is not supported because all copies are rendered unusable.

With the ability to install multiple copies of Db2 products on your system and the flexibility to install Db2 products and features in the path of your choice, the db2ls command helps you keep track of what is installed and where it is installed. Run the db2ls command to locate Db2 products installed on your system.

The following restrictions apply when installing multiple Db2 copies on one system:
  • Non-root installations do not support multiple Db2 copies
  • There can be only one Db2 Administration Server (DAS) on the system.
  • Instance names must be unique across Db2 copies.
  • A Db2 copy is not aware of any instances created in another Db2 copy. However, the db2iupdt command can switch ownership of an instance from one Db2 copy to another.
  • Creating links with the db2ln command for one Db2 copy renders the other copies nonfunctional. Links must not be created when multiple Db2 copies are intended to coexist.
  • Linux 32-bit images cannot be installed on Linux x64 operating system platforms.
  • The Db2 installation tools do not support multiple simultaneous invocations on the same machine by the same user.
  • The installation paths cannot be symbolic links.