java.lang.NoClassDefFoundError: Could not initialize class com.datastax.driver.core.Cluster

Hi, community,  

I am using Streamset data collector for data migration from PostgreSQL to Cassandra But while testing the Cassandra connection I am encountering the above error.


12 replies

Userlevel 4

Hello @sanket.bhendarkar - Thank you for reaching out the StreamSets community. I was able to run a test on Cassandra connection in my workstation and it is working fine. Before creating the connection, I installed the Cassandra Java Driver 3.x from the package manager.


Could you please login to the Data collector and confirm if you see Cassandra Java Driver 3.x and check if jar’s available under $SDC_HOME/streamsets-libs/streamsets-datacollector-cassandra* path?

Thank you, Akshay. could you please let me know how to checked installed drivers in streamsets? I am new to streamsets 

Userlevel 4

Thank you @sanket.bhendarkar - You can login to the SDC UI » Package Manger » Installed Stage Libraries and search for Cassandra?


Dont have pakage manager

I have deleted some externally uploaded libraries, now I have an authentication error. I have cross-checked my Cassandra credentials they are working locally


Userlevel 4

I’m glad that NoClassDefFoundError has been resolved. 

Could you please run the following command from the data collector host and confirm if Cassandra is installed on the same data collector host? 

  • Login to Linux Box.
  • Run the command to check if it is connected:
    • cqlsh hostname -u <username> -p <password>

Also make sure that you select the proper protocol version.

thanks, Akshay, 

I have installed a streamsets data collector using the docker. could you please let me know how to check 

Cassandra is installed on the data collector host?

Userlevel 4

Hello @sanket.bhendarkar - I wanted to ask if data collector and Cassandra is hosted on the same host however data collector is running as a docker then Cassandra might be installed somewhere else.

Could you please check, on which host Cassandra is installed and Can you make sure that data collector host is able to reach out to the Cassandra server. 

  1. login to the docker container:
    1. docker exec -it <conatinerID> /bin/bash
    2. ping <CassandraHOST>
  2. Run the cqlsh hostname -u <username> -p <password> where Cassandra is installed and used same credential which are mentioned in DataCollector to confirm username/password is correct. 

using the docker container I am able to ping Cassandra's host also I have cross-checked my Cassandra credentials using cqlsh hostname -u <username> -p <password>  command . still facing the same authentication error

Userlevel 4

Thank you for writing in. Could you please quickly collect the logs and share it with us?


In the log section, we don't have a download button, please let me know how can I download logs. 

Userlevel 4

Hi @sanket.bhendarkar  - You can download the logs by using the docker cp command, just mentioned the correct log file path of data collector to the command:

docker cp <containerId>:/file/path/within/container /host/path/target


If you are using the DataOps platform, you can navigate to DataOpsUI» Set UP » Engine » Click on engine and go to the support bundle section. This will download the .zip file which will be having the pipelines+logs+configuration.


If the docker container has the Data Collector UI, you can navigate to SDC UI»Administration » Logs» Download sdc.log.


Let me know if you have any questions on this.