chuqbach/Big-Data-Installation

Exception in thread "main" java.lang.NoSuchMethodError: com.google.common.base.Preconditions.checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V

Closed this issue · 3 comments

Issue happens when start Hive

This issue happened because guava lib version is different in Hive lib folder and Hadoop shared folder.

To fix this, we need to ensure the versions are consistent.

  • Go to $HIVE_HOME (%HIVE_HOME%)/lib folder and find out the version of guava. For Hive 3.0.0, it is guava-19.0.jar.
  • Go to $HADOOP_HOME (%HADOOP_HOME%)/share/hadoop/common/lib folder and out the version of guava. For Hadoop 3.2.1, the version is guava-27.0-jre.jar.
  • If they are not same (which is true for this case), delete the older version and copy the newer version in both. In this case, delete guava-19.0.jar in Hive lib folder, and then copy guava-27.0-jre.jar from Hadoop folder to Hive.

Thanks for your help

Please this didn't work for me, what else can I try?