===== DB2 connector ===== ==== Purpose ==== * With the DB2 connector, you can connect to an DB2 database via a JDBC driver.\\ * The database will then be monitored by querying information from the database with SQL requests * To create connector, there are two steps: * Create a user in the database and register it in Redpeaks * Create and set connector parameters ==== Drivers ==== The driver db2jcc4 can be download on Maven repository : https://mvnrepository.com/artifact/com.ibm.db2.jcc/db2jcc/db2jcc4 ==== Create user profile ==== * User profiles can be created via the Configure menu * Once created, the user profile can be selected in the connector form * Note: A user profile is by default associated with a company . You can explicitly set a profile to be cross companies. The effect is that it will be selectable from connectors of any companies. * The corresponding user must be created in the database as well. ==== Create connector ==== * Select the system in the Systems tree and select “Add connector” in its contextual menu, choose DB2 type. * Fill in the connector parameters: * **Title** The display name of the connector * **Host:** The hostname or IP address of the database host * **Port:** The port of the database service * If on **Db2 Version 11.5.5 and older**, the default port number is **50000**. * If on **Db2 Version 11.5.6 and newer**, the default port number is **25000** * **Database name:** The database to connect to * **User:** The user profile to use for the connection * **Properties:** Optional properties to add to the connection parameters (separated with semicolon (;) **Press Save & Test** to save the profile and check the connection is working {{.:db2.png}} ==== SSH ==== * In case you must connect to a database through an SSH tunnel, you can enable the SSH option and fill in the parameter: * **Host:** The host where the entrance of the tunnel is created. * **Port:** The local port of the SSH tunnel * **User:** The user to authenticate on the SSH end point. {{.:db2_ssh.png}} ==== Custom timeout ==== * See [[.:common|Custom timeouts]] ==== Authorizations ==== The DB2 monitors will need to peform SELECT queries on the below tables: In progress...