Install JDBC Driver on Meridian Core

To detect, poll, or collect any JDBC service, you must install the appropriate JDBC driver.

  1. Download the JDBC driver JAR file from a repository (for example, a public Maven repository) or from the database vendor.

  2. Install the JAR file in ${OPENNMS_HOME}/lib/.

  3. Restart Meridian.

Test an installed JDBC driver

Connect to the Karaf shell
ssh -p 8101 admin@localhost
Attempt an ad hoc collection using the database driver
collect org.opennms.netmgt.collectd.JdbcCollector driver=org.mysql.jdbc.Driver collection=MySQL-Global-Stats-51 url=jdbc:mysql://OPENNMS_JDBC_HOSTNAME:3306/test
If the JDBC driver is not available or the driver classname is incorrect, the collect command returns an error
Collect failed with: java.util.concurrent.ExecutionException: java.lang.RuntimeException: Unable to load driver class: java.lang.ClassNotFoundException: org.mariadb.jdbc.Driver