Support Questions
Find answers, ask questions, and share your expertise

Metron rest fails to start on Ambari installed cluster - Cannot load driver class: com.mysql.jdbc.Driver

Metron rest fails to start on Ambari installed cluster - Cannot load driver class: com.mysql.jdbc.Driver

Contributor

Metron rest service getting stopped once started.

I am trying this on cent os 7 amazon ec2 instance.

Error I get in the configured host is

caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.tomcat.jdbc.pool.DataSource]: Factory method 'dataSource' threw exception; nested exception is java.lang.IllegalStateException: Cannot load driver class: com.mysql.jdbc.Driver at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:189) at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588) ... 41 more Caused by: java.lang.IllegalStateException: Cannot load driver class: com.mysql.jdbc.Driver at org.springframework.util.Assert.state(Assert.java:392) at org.springframework.boot.autoconfigure.jdbc.DataSourceProperties.determineDriverClassName(DataSourceProperties.java:214) at org.springframework.boot.autoconfigure.jdbc.DataSourceProperties.initializeDataSourceBuilder(DataSourceProperties.java:174) at org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration.createDataSource(DataSourceConfiguration.java:42) at org.springframework.boot.autoconfigure.jdbc.DataSourceConfiguration$Tomcat.dataSource(DataSourceConfiguration.java:53) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Nati

Seems the jdbc driver class cannot be loaded. I have downloaded the mysql connector jar in the host and the jar path is configured in Metron JDBC client path.

screenshot-from-2018-01-26-22-09-07.png

2 REPLIES 2

Re: Metron rest fails to start on Ambari installed cluster - Cannot load driver class: com.mysql.jdbc.Driver

Super Mentor

@Irshad Muhammed

For the same queries please do not open multiple HCC threads.

We see that you have already opened another HCC thread for the same query here: https://community.hortonworks.com/questions/168896/metron-rest-not-starting-using-ambari-cluster-due...

Please close one of them so that the discussion is dedicated to only one thread.

Re: Metron rest fails to start on Ambari installed cluster - Cannot load driver class: com.mysql.jdbc.Driver

Contributor

ooh. Was made by mistake. Will close this one.

,

oh sorry. Will close this one.