请稍等 ...
×

采纳答案成功!

向帮助你的同学说点啥吧!感谢那些助人为乐的人

我用的是mysql8,mac 系统,

我真的花了一天时间整这个hive环境的搭建,老是出出问题,我真的没有办法去解决了,求老师帮我一下。我用的mac系统,用的是mysql8.0.安装hive时,配置文件完全按照老师讲的来弄。就是和老师的结果不一样,我已经弄了一天,网上查也查了,就是出现以下的问题:

  1. Establishing SSL connection without server’s identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn’t set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to ‘false’. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification;
  2. Exception in thread “main” java.lang.RuntimeException: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient
    3 Caused by: java.lang.RuntimeException: Unable to instantiate org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient
    at org.apache.hadoop.hive.metastore.MetaStoreUtils.newInstance(MetaStoreUtils.java:1492)

4.Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at
Caused by: javax.jdo.JDODataStoreException: Error(s) were found while auto-creating/validating the datastore for classes. The errors are printed in the log, and are attached to this exception.
er.makePersistent(JDOPersistenceManager.java:752)
at
at org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient.(SessionHiveMetaStoreClient.java:74)
… 18 more
Caused by: java.sql.SQLSyntaxErrorException: Table ‘sparksql.version’ doesn’t exist
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:120)
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
at com.mysql.cj.jdbc.StatementImpl.executeInternal(StatementImpl.java:781)
at com.mysql.cj.jdbc.StatementImpl.execute(StatementImpl.java:666)
at com.jolbox.bonecp.StatementHandle.execute(StatementHandle.java:254)
at org.datanucleus.store.rdbms.table.AbstractTable.executeDdlStatement(AbstractTable.java:760)
at org.datanucleus.store.rdbms.table.AbstractTable.executeDdlStatementList(AbstractTable.java:711)
at org.datanucleus.store.rdbms.table.TableImpl.validateColumns(TableImpl.java:259)
at org.datanucleus.store.rdbms.RDBMSStoreManagerClassAdder.performTablesValidation(RDBMSStoreManager.java:3393)atorg.datanucleus.store.rdbms.RDBMSStoreManagerClassAdder.performTablesValidation(RDBMSStoreManager.java:3393) at org.datanucleus.store.rdbms.RDBMSStoreManagerClassAdder.performTablesValidation(RDBMSStoreManager.java:3393)atorg.datanucleus.store.rdbms.RDBMSStoreManagerClassAdder.addClassTablesAndValidate(RDBMSStoreManager.java:3190)
at org.datanucleus.store.rdbms.RDBMSStoreManager$ClassAdder.run(RDBMSStoreManager.java:2841)
at org.datanucleus.store.rdbms.AbstractSchemaTransaction.execute(AbstractSchemaTransaction.java:122)
at org.datanucleus.store.rdbms.RDBMSStoreManager.addClasses(RDBMSStoreManager.java:1605)
at org.datanucleus.store.AbstractStoreManager.addClass(AbstractStoreManager.java:954)
at org.datanucleus.store.rdbms.RDBMSStoreManager.getDatastoreClass(RDBMSStoreManager.java:679)
at org.datanucleus.store.rdbms.RDBMSStoreManager.getPropertiesForGenerator(RDBMSStoreManager.java:2045)
at org.datanucleus.store.AbstractStoreManager.getStrategyValue(AbstractStoreManager.java:1365)
at org.datanucleus.ExecutionContextImpl.newObjectId(ExecutionContextImpl.java:3827)
at org.datanucleus.state.JDOStateManager.setIdentity(JDOStateManager.java:2571)
at org.datanucleus.state.JDOStateManager.initialiseForPersistentNew(JDOStateManager.java:513)
at org.datanucleus.state.ObjectProviderFactoryImpl.newForPersistentNew(ObjectProviderFactoryImpl.java:232)
at org.datanucleus.ExecutionContextImpl.newObjectProviderForPersistentNew(ExecutionContextImpl.java:1414)
at org.datanucleus.ExecutionContextImpl.persistObjectInternal(ExecutionContextImpl.java:2218)
at org.datanucleus.ExecutionContextImpl.persistObjectWork(ExecutionContextImpl.java:2065)
at org.datanucleus.ExecutionContextImpl.persistObject(ExecutionContextImpl.java:1913)
at org.datanucleus.ExecutionContextThreadedImpl.persistObject(ExecutionContextThreadedImpl.java:217)
at org.datanucleus.api.jdo.JDOPersistenceManager.jdoMakePersistent(JDOPersistenceManager.java:727)
… 36 more

正在回答

2回答

请换成mysql 5.6问题就可以解决

1 回复 有任何疑惑可以回复我~
  • 提问者 maomaoking #1
    谢谢!装MySQL也出现了不少问题,但是也解决!
    回复 有任何疑惑可以回复我~ 2018-09-17 20:44:07
Michael_PK 2018-09-15 18:16:11

1好像不是error把,2一再强调严格按照上课版本来,你确定hive能支持MySQ吗?

0 回复 有任何疑惑可以回复我~
  • 提问者 maomaoking #1
    Hive是老师给的!MySQL8是自己安装在Mac上的!
    回复 有任何疑惑可以回复我~ 2018-09-15 18:20:11
  • Michael_PK 回复 提问者 maomaoking #2
    hive官网查下是否支持MySQL8
    回复 有任何疑惑可以回复我~ 2018-09-15 18:21:29
  • 被吊打的学渣 回复 提问者 maomaoking #3
    你想用高版本的mysql,也同时要用高版本的hive。 版本跨度过大是不行的。上面那个错误你把sparksql删了再重新创建就可以解决,但是你依然进不了hive cli界面,会出现悬停状态。所以把mysql数据库删了,安装一个5.6版本的就可以解决。
    回复 有任何疑惑可以回复我~ 2018-09-15 19:13:24
问题已解决,确定采纳
还有疑问,暂不采纳
意见反馈 帮助中心 APP下载
官方微信