Third-party postgresql-jdbc driver causes errors on Red Hat Satellite 5.7

Solution Verified - Updated -

Issue

Red Hat Satellite 5.7 throws these errors:

  • /var/log/tomcat/catalina.out
2017-05-23 16:08:21,748 [TP-Processor8] ERROR org.hibernate.connection.ConnectionProviderFactory - Could not instantiate connection provider: org.hibernate.connection.C3P0ConnectionProvider
Unsupported connection provider implemention is not included our Product.
This error may be caused by the configured connection provider was not found in the classpath.
Please check the connection configuration and make sure the provider is in the classpath.
java.lang.UnsupportedClassVersionError: JVMCFRE003 bad major version; class=org/postgresql/Driver, offset=6 (unable to load class org.postgresql.Driver)
    at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2334)
    at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:976)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1450)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1329)
    at java.lang.Class.forNameImpl(Native Method)
(...)
  • /var/log/tomcat/catalina.out
2017-05-23 16:08:21,749 [TP-Processor8] ERROR com.redhat.rhn.common.hibernate.ConnectionManager - FATAL ERROR creating HibernateFactory
org.hibernate.HibernateException: Could not instantiate connection provider: org.hibernate.connection.C3P0ConnectionProvider
Unsupported connection provider implemention is not included our Product.
This error may be caused by the configured connection provider was not found in the classpath.
Please check the connection configuration and make sure the provider is in the classpath.
    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:146)
    at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:78)
    at org.hibernate.cfg.SettingsFactory.createConnectionProvider(SettingsFactory.java:430)
    at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:90)
    at org.hibernate.cfg.Configuration.buildSettingsInternal(Configuration.java:2118)
    at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2114)
    at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1338)
    at com.redhat.rhn.common.hibernate.ConnectionManager.createSessionFactory(ConnectionManager.java:205)
(...)
  • /var/log/tomcat/catalina.out
2017-05-23 16:08:21,749 [TP-Processor8] ERROR com.redhat.rhn.frontend.servlets.SessionFilter - Error during transaction. Rolling back
java.lang.NullPointerException
    at com.redhat.rhn.common.hibernate.ConnectionManager.getInternalSession(ConnectionManager.java:280)
    at com.redhat.rhn.common.hibernate.ConnectionManager.getSession(ConnectionManager.java:270)
    at com.redhat.rhn.common.hibernate.HibernateFactory.getSession(HibernateFactory.java:321)
    at com.redhat.rhn.common.db.datasource.CachedStatement.stealConnection(CachedStatement.java:888)
    at com.redhat.rhn.common.db.datasource.CachedStatement.executeCallable(CachedStatement.java:523)
    at com.redhat.rhn.common.db.datasource.CallableMode.execute(CallableMode.java:35)
    at com.redhat.rhn.common.hibernate.HibernateFactory.executeCallableMode(HibernateFactory.java:605)
    at com.redhat.rhn.domain.common.LoggingFactory.clearLogId(LoggingFactory.java:48)
    at com.redhat.rhn.frontend.servlets.SessionFilter.doFilter(SessionFilter.java:56)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at com.redhat.rhn.frontend.servlets.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:97)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
(...)

Environment

  • Red Hat Satellite 5.7
  • JRE 1.7.1-ibm:
# alternatives --config java
(...)
 +  /usr/lib/jvm/jre-1.7.1-ibm.x86_64/bin/java
(...)
  • postgresql-jdbc package not provided by Red Hat

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In