Getting MissingTableException: Required table miss

2019-09-08 03:44发布

Hive with mysql as the metadata store stopped working:

Caused by: org.datanucleus.store.rdbms.exceptions.MissingTableException: 
Required table missing : "`VERSION`" in Catalog "" Schema "". DataNucleus
requires this table to perform its persistence operations. Either your 
MetaData is incorrect, or you need to enable "datanucleus.autoCreateTables"

Setting the autoCreateTables is not working either:

<property>
<name>datanucleus.autoCreateTables</name>
<value>True</value>
</property>

So how to fix this?

标签: mysql hive
2条回答
萌系小妹纸
2楼-- · 2019-09-08 04:12

Check your permissions, it is more likely the user that you are using doesn't have permission to create privileges.

Here is my scenario:

I had faced the same error when I was installing Sentry service on Cloudera manager 5.7.6. i have set up sentry database as MySQL database. It is all in GUI and 6 steps process, This issue occurred on the 5th one

What confuses you is tasks says "Create Sentry Database Tables" 'Successfully created Sentry database tables' but it only checks for the access to the database.

After I have change permissions it worked.

查看更多
够拽才男人
3楼-- · 2019-09-08 04:13

Go to the $HIVE_HOME and run the initschema option on the schematool:

bin/schematool -dbType mysql -initSchema
查看更多
登录 后发表回答