Problem connecting Sqoop to MySql

0 votes

Hi. I am facing some issue with connecting Sqoop to MySql. I am connecting it using the following command:

$ sqoop import --connect jdbc:mysql://localhost/employees

It is getting connected to random database and not to the employees database. Please help, what am I doing wrong?

May 15 in Big Data Hadoop by Kurian
53 views

Why are you using localhost? You should give the host name.

Hey @Raj, I am using localhost because I am running on my local system and not on a server.

1 answer to this question.

0 votes

Perhaps, you have slightly misunderstood the method to connect it. Even if you are running it on the local system, you have to specify the hostname. When you use localhost, it doesn't connect to a database because the database is pointed by the url containing the hostname. So mention the hostname, it should work:

$ sqoop import --connect jdbc:mysql://<hostname>/employees
answered May 15 by Ali

Related Questions In Big Data Hadoop

0 votes
1 answer

Sqoop getting error while connecting to MySQL

Have you set a password for MySQL? ...READ MORE

answered Feb 7 in Big Data Hadoop by Omkar
• 67,140 points
35 views
0 votes
1 answer
0 votes
1 answer

Sqoop error while trying to connect to MySql

Please use the below command to solve ...READ MORE

answered May 22 in Big Data Hadoop by Bhagavath
21 views
0 votes
1 answer

Is there any way to load data from MySql to HDFS?

The generic command i.e used to import ...READ MORE

answered Apr 10, 2018 in Big Data Hadoop by nitinrawat895
• 10,150 points
403 views
0 votes
1 answer

Update hdfs data before stroring in MySql

Yes, you can update the data before ...READ MORE

answered Jan 27 in Big Data Hadoop by Omkar
• 67,140 points
20 views
0 votes
1 answer
0 votes
2 answers
0 votes
1 answer
0 votes
1 answer

Sqoop import failed while importing mysql table to Hbase

There is a spelling mistake in your ...READ MORE

answered Feb 6 in Big Data Hadoop by Omkar
• 67,140 points
110 views
0 votes
1 answer

Sqoop transfer file from MySql to HBase

Sqoop doesn’t permit you to import, all ...READ MORE

answered Feb 11 in Big Data Hadoop by Omkar
• 67,140 points
63 views