hive安装报错:Class path contains multiple SLF4J bindings

报错如下:

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/local/hive/lib/log4j-slf4j-impl-2.10.0.jar!/org/slf4j/impl/StaticLoggerBinder.clas
SLF4J: Found binding in [jar:file:/usr/local/hadoop/share/hadoop/common/lib/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/Stat
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]

错误原因:

hive和hadoop中的SLF4J重复了
在两个中的位置分别如下:
- /usr/local/hive/lib/
- /usr/local/hadoop/share/hadoop/common/lib/

解决办法:

删除任意一个 log4j-slf4j-impl.jar 即可,
建议保留版本高版本。

原文地址:https://www.cnblogs.com/jaysonteng/p/13412728.html