Start hive error: java.lang.NoSuchMethodError: com.google.common.base.Preconditions.checkArgument (ZLjava / lang / String; Ljava / lang / Object;) V (Resolved)

Error details:

From the point of view error message:

一,java.lang.NoSuchMethodError

  Reasons: 1. The system can not find the relevant jar package

                  2. The same type of jar package has a different version exists, the system can not decide which one to use

二,com.google.common.base.Preconditions.checkArgument

The Baidu understood, from the class guava.jar

Third, view the version information in hadoop jar package and hive in

  hadoop-3.2.1 (path: hadoop \ share \ hadoop \ common \ lib) in the jar package for  guava-27.0-jre.jar

 

   hive-2.3.6 (path: hive / lib) in the jar package for guava-14.0.1.jar

  

Fourth, the solution

Delete hive in a low version of guava-14.0.1.jar package, hadoop of guava-27.0-jre.jar copied to the lib directory hive can be.

Fifth, the successful operation hive

 

Guess you like

Origin www.cnblogs.com/mawangwang/p/11854762.html