I tried to set up sqoop (sqoop-1.4.3.bin__hadoop-1.0.0) on Ubuntu. I can run the basic sqoop help etc without problems. When I run the following I get an error:
I had the same issue on Ubuntu.
My $JAVA_HOME was correctly set to /usr/lib/jvm/java-7-openjdk-amd64, but looking into /usr/lib/jvm/java-7-openjdk-amd64/bin I noticed that "javac" was not there. That's what Sqoop needs but could not find.
So the problem was simply that my installation of Java came without Java compiler. The solution was then very simple:
sudo apt-get install openjdk-7-jdk
Sqoop will eventually execute Hadoop shell script, so I would make sure that your Hadoop is configured properly to use the JDK instead of JRE.
Scoop creates java classes that represent the schema of the table you are importing in. So to create the classes you need the jdk instead of the jre.
Set the JAVA_HOME in the ./bashrc
and the $HADOOP_HOME/conf/hadoop-env.sh
as well.
That should work.