ERROR pig.Main: ERROR 2998: Unhandled internal error. com.google.common.base.Preconditions.checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V
WARN pig.Main: There is no log file to write to.
ERROR pig.Main: java.lang.NoSuchMethodError: com.google.common.base.Preconditions.checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V
Above is the pig installation error I got. Any fix?
It is mostly caused due to the 'Guava jar issue'.
Check 'Guava' jar version in Hadoop and Pig.
ls $PIG_HOME/lib
ls $HADOOP_HOME/share/hadoop/hdfs/lib
Delete Guava jar in Pig
rm $PIG_HOME/lib/guava-19.0.jar
Copy Guava jar from Hadoop to Pig
cp $HADOOP_HOME/share/hadoop/hdfs/lib/guava-27.0-jre.jar $PIG_HOME/lib/
For more info follow this doc, but replace 'hive' with 'pig' everywhere http://cis.csuohio.edu/~sschung/cis612/CIS612_Lab4_2_Hive_CommonInstallationProblems.pdf