【大数据报错】hive3初始化数据库报错

在使用hive3.1.1版本初始化连接到MySQL的元数据存储时遇到错误,SLF4J绑定冲突和ClassNotFoundException: com.mysql.cj.jdbc.Driver。解决方法是将配置文件hive-site.xml中`javax.jdo.option.ConnectionDriverName`的值从`com.mysql.cj.jdbc.Driver`改为`com.mysql.jdbc.Driver`,然后重新初始化Hive,问题得到解决。
摘要由CSDN通过智能技术生成

hive3初始化数据库报错

场景:
hive版本:3.1.1
Hadoop版本:HA3.1.1
系统:CentOS 7.6


hive03.1.1初始化MySQL远程数据库报错:
$ schematool -dbType mysql -initSchema
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/opt/hive/apache-hive-3.1.1/lib/log4j-slf4j-impl-2.10.0.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/opt/hadoop-3.1.1/share/hadoop/common/lib/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.apache.logging.slf4j.Log4jLoggerFactory]
Metastore connection URL:        jdbc:mysql://192.168.1.18:3306/hive
Metastore Connection Driver :    com.mysql.cj.jdbc.Driver
Metastore connection User:       root
org.a

  • 1
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值