pig installation according to the instructions , module 6

I tried to install Pig for demo VM
according to the instructions I added at the end of .bashrc:
"export JAVA_HOME=/usr/lib/jvm/java-6-sun-"

I closed the terminal and I opened another terminal and I typed: pig
[cloudera@localhost ~]$ pig
/usr/lib/hbase/bin/hbase: line 231: /usr/lib/jvm/java-6-sun- No such file or directory
/usr/lib/hadoop/bin/hadoop: line 139: /usr/lib/jvm/java-6-sun- No such file or directory
/usr/lib/hadoop/bin/hadoop: line 139: exec: /usr/lib/jvm/java-6-sun- cannot execute: No such file or directory

I can't go to the grunt shell for pig installation

Any help is appreciated
Thank you

2 Answer(s)


hi Lambrini,

Cloudera VM comes with Apache Pig installed and if you try to install Pig in this environment, it may clash with existing libraries.

Try setting up Apache Pig in a vanilla CentOS or Ubuntu and before setting up Pig make sure to install Hadoop as well.



Thank you for your message.
I see in Cloudera VM that java is : jdk1.6.0_32 and it is in:

After that if I continue with Cloudera VM I have to update the .bashrc with the location of java and continue with installation of pig (according to manual installation of Demo VM).
Probably this process will work for pig installation and it will use the pig from the Cloudera VM.
Please let me know if I am correct.
Thank you.