Start kylin and report an error: com.google.common.base.Preconditions.checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V

created at 01-15-2022 views: 4

problem

error message

Caused by: java.lang.NoSuchMethodError: com.google.common.base.Preconditions.checkArgument(ZLjava/lang/String;Ljava/lang/Object;)V
    at org.apache.hadoop.conf.Configuration.set(Configuration.java:1358)
    at org.apache.hadoop.conf.Configuration.set(Configuration.java:1339)
    at org.apache.kylin.common.util.HadoopUtil.healSickConfig(HadoopUtil.java:77)
    at org.apache.kylin.common.util.HadoopUtil.getCurrentConfiguration(HadoopUtil.java:63)
    at org.apache.kylin.storage.hbase.HBaseConnection.newHBaseConfiguration(HBaseConnection.java:170)
    at org.apache.kylin.storage.hbase.HBaseConnection.get(HBaseConnection.java:259)
    at org.apache.kylin.storage.hbase.HBaseResourceStore.getConnection(HBaseResourceStore.java:96)
    at org.apache.kylin.storage.hbase.HBaseResourceStore.createHTableIfNeeded(HBaseResourceStore.java:119)
    at org.apache.kylin.storage.hbase.HBaseResourceStore.<init>(HBaseResourceStore.java:89)
    ... 8 more

solution:

Copy the guava dependencies in the Hadoop cluster to

  • $KYLIN_HOME/tool/
  • and $KYLIN_HOME/tomcat/lib/

directories, then restart kylin bin/kylin.sh restart.

cp $HADOOP_HOME/share/hadoop/common/lib/guava-27.0-jre.jar $KYLIN_HOME/tool/

cp $HADOOP_HOME/share/hadoop/common/lib/guava-27.0-jre.jar $KYLIN_HOME/tomcat/lib/
created at:01-15-2022
edited at: 01-15-2022: