Ask Your Question
0

java.lang.NoClassDefFoundError: Could not initialize class com.mysql.jdbc.Driver

asked 2018-06-20 23:17:27 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

when i use mysql to hive,and i preview use the "jdbc query consumer",it issue "java.lang.NoClassDefFoundError: Could not initialize class com.mysql.jdbc.Driver".

JDBC Driver Class Name : com.mysql.jdbc.Driver mysql driver is :mysql-connector-java-5.1.46-bin.jar

edit retag flag offensive close merge delete

Comments

This happens mostly in case of missing mysql connector jar.Suppose it is giving error even after placing the jar there might be issues in your connection URL or the credentials.If you have placed the jar file after starting Streamsets,try restart and run the pipeline.

Maithri gravatar imageMaithri ( 2018-06-20 23:38:18 -0500 )edit

url is jdbc:mysql://IP:3308/test I try restare after i upload the "mysql-connector-java-5.1.46-bin.jar" , but the problem is still exist!

supersujj gravatar imagesupersujj ( 2018-06-21 01:09:55 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-06-21 03:14:11 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

it solution, i found the problem is not set "Data Collector Advanced Configuration Snippet (Safety Valve) for sdc-security.policy",after i set, it work normal.

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-06-20 23:17:27 -0500

Seen: 24 times

Last updated: Jun 21