Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.0.0
Description
The change in HIVE-22546 is causing following stack trace when I run Hive with PostgreSQL as backend db for the metastore.
0: jdbc:hive2://localhost:10000> create database dumpdb with ('repl.source.for'='1,2,3');0: jdbc:hive2://localhost:10000> create database dumpdb with ('repl.source.for'='1,2,3');Error: Error while compiling statement: FAILED: ParseException line 1:28 missing KW_DBPROPERTIES at '(' near '<EOF>' (state=42000,code=40000)0: jdbc:hive2://localhost:10000> create database dumpdb with dbproperties ('repl.source.for'='1,2,3');ERROR : FAILED: Hive Internal Error: org.apache.hadoop.hive.ql.lockmgr.LockException(Error communicating with the metastore)org.apache.hadoop.hive.ql.lockmgr.LockException: Error communicating with the metastore at org.apache.hadoop.hive.ql.lockmgr.DbTxnManager.commitTxn(DbTxnManager.java:541) at org.apache.hadoop.hive.ql.Driver.releaseLocksAndCommitOrRollback(Driver.java:687) at org.apache.hadoop.hive.ql.Driver.releaseLocksAndCommitOrRollback(Driver.java:653) at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:969)
... stack trace clipped
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)Caused by: MetaException(message:Unable to update transaction database org.postgresql.util.PSQLException: ERROR: relation "materialization_rebuild_locks" does not exist Position: 13 at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2440) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2183) at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:308) at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:441) at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:365) atÂ
This happens because the table names in all the queries in TxnHandler.java (including the one at 1312, which causes this stack trace) are not quoting the table names. All the tablenames and column names should be quoted there. Just the change in HIVE-22546 won't suffice.
Attachments
Attachments
Issue Links
- links to