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
chuqbach commented
Issue happens when start Hive
chuqbach commented
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 isguava-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 isguava-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 copyguava-27.0-jre.jar
from Hadoop folder to Hive.
rocarva commented
Thanks for your help
Uju-Chinedum commented
Please this didn't work for me, what else can I try?