zoukankan      html  css  js  c++  java
  • Error: Duplicate key name 'PCS_STATS_IDX' (state=42000,code=1061) ----Hive schematool -initSchema -dbType mysql

    schematool -initSchema -dbType mysql
    Metastore connection URL: jdbc:mysql://localhost/metastore_db?createDatabaseIfNotExist=true
    Metastore Connection Driver : com.mysql.jdbc.Driver
    Metastore connection User: hiveuser
    Starting metastore schema initialization to 2.1.0
    Initialization script hive-schema-2.1.0.mysql.sql
    Error: Duplicate key name 'PCS_STATS_IDX' (state=42000,code=1061)
    org.apache.hadoop.hive.metastore.HiveMetaException: Schema initialization FAILED! Metastore state would be inconsistent !!
    Underlying cause: java.io.IOException : Schema script failed, errorcode 2
    Use --verbose for detailed stacktrace.
    *** schemaTool failed ***

    以上错误查看mysql是否已经创建了metastore batabase, 如果创建,直接删除即可。

  • 相关阅读:
    Win7 安装
    线上java排查
    spring boot
    redisson
    Jcaptca 图片
    URL重写
    gradle导出依赖的jar包
    Redis tomcat
    flex 通过htmlservices链接moss的rest(rest 的get post方式)
    java语言MySQL批处理
  • 原文地址:https://www.cnblogs.com/Jesse-Li/p/7919118.html
Copyright © 2011-2022 走看看