Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

Sqoop - missing driver or something else?

avatar
Contributor

Hi,

my ultimate goal is to get some data from SQL Server and import it to HDFS, after discussions with others they have said I am best extracting the data with Sqoop to AVRO files and then creating a HIVE table based on them.

So to do this I'm starting at the beginnning.

Step 1 getting Sqoop to connect to the table, at this point it doesn't have to do anything with it.

In Step 2 I'll worry about extract it AVRO files

So I put together the following command

sqoop import --connect "jdbc:sqlserver://<SQLSERVER>:1433;database=sandbox;user=hdfsuser;password=hdfspassword" --table policy 

And Scoop goes off to try and do it but then I get the following back

Could not load db driver class: com.microsoft.sqlserver.jdbc.SQLServerDriver java.lang.RuntimeException: Could not load db driver class: com.microsoft.sqlserver.jdbc.SQLServerDriver

Does this mean that I need to install it as detailed here;

http://stackoverflow.com/questions/23096655/sqoop-connecting-to-sql-server

Or am I barking up the wrong tree.

I'm having to do a Hadoop POC all on my own so having you all to bounce my ideas off and get help from is a real plus so thanks for taking the time to read all this and any help would be massively appreciated by me.

Thanks, Nic

1 ACCEPTED SOLUTION

avatar

You are correct, you need to first install the SQL server connector.

https://community.hortonworks.com/questions/1941/sqoop-connector-for-microsoft-sql-server.html

You will need to copy it into /usr/hdp/current/sqoop-client/lib/

View solution in original post

3 REPLIES 3

avatar

You are correct, you need to first install the SQL server connector.

https://community.hortonworks.com/questions/1941/sqoop-connector-for-microsoft-sql-server.html

You will need to copy it into /usr/hdp/current/sqoop-client/lib/

avatar
Contributor

Thanks for confirming that, I'll give it a try on Monday, have a great weekend.

Nic

avatar
Contributor

That did the job for me. Thanks again.