user9657929
user9657929

Reputation: 1

files not showing after sqoop import

After successfully importing one table from MySql to Hadoop, not able to see any files under hadoop path. Import command:

sqoop import --connect jdbc:mysql://quickstart:3306/lipu --username root --password cloudera --table student --target-dir =/user/cloudera/jds --m 1 

It is successful as it is finaly saying the number of records it retrieves. But when I am checking the contents inside my target directory, it is not showing anything.

 hadoop fs -ls  /user/cloudera/jds

The above command is not returning anything.
Need your help .

Upvotes: 0

Views: 234

Answers (1)

Dharmik Thakkar
Dharmik Thakkar

Reputation: 11

You need to remove = after target-dir. Try running:

sqoop import --connect jdbc:mysql://quickstart:3306/lipu --username root --password cloudera --table student --target-dir /user/cloudera/jds --m 1

followed by hadoop fs -ls /user/cloudera/jds.

Upvotes: 1

Related Questions