[
https://issues.apache.org/jira/browse/HIVE-4102?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13697566#comment-13697566
]
Deepesh Khandelwal commented on HIVE-4102:
------------------------------------------
I have seen tables in Hive schema lock up in Postgres if the Hive schema is not
pre-initialized. Use the script
/metastore/scripts/upgrade/postgres/hive-schema-0.10.0.postgres.sql to
preinitialize the schema in postgres before starting the hive server. That
should help.
> Can't drop table with Postgresql metastore
> ------------------------------------------
>
> Key: HIVE-4102
> URL: https://issues.apache.org/jira/browse/HIVE-4102
> Project: Hive
> Issue Type: Bug
> Components: Database/Schema
> Affects Versions: 0.10.0
> Environment: Centos 6.3
> CDH 4.2.0
> Reporter: sekine coulibaly
>
> Setup a fresh hive install, create a table pointing to an HDFS file.
> Then, when trying to drop that table, the CLI hangs for a while and then
> displays :
> hive> drop table log;
> FAILED: Error in metadata: org.apache.thrift.transport.TTransportException:
> java.net.SocketTimeoutException: Read timed out
> FAILED: Execution Error, return code 1 from
> org.apache.hadoop.hive.ql.exec.DDLTask
> Trying another time :
> hive> drop table log;
> FAILED: SemanticException [Error 10001]: Table not found log
> getting tables list :
> hive> show tables;
> FAILED: Error in metadata: MetaException(message:Got exception:
> org.apache.thrift.transport.TTransportException
> java.net.SocketTimeoutException: Read timed out)
> FAILED: Execution Error, return code 1 from
> org.apache.hadoop.hive.ql.exec.DDLTask
> hive>
> For this last query, the Postgresql logs showthe following :
> LOG: connection received: host=127.0.0.1 port=49717
> LOG: connection authorized: user=hiveuser database=metastore
> LOG: execute <unnamed>: SHOW TRANSACTION ISOLATION LEVEL
> LOG: execute S_1: BEGIN
> LOG: execute <unnamed>: SELECT
> 'org.apache.hadoop.hive.metastore.model.MDatabase' AS
> NUCLEUS_TYPE,"THIS"."DESC","THIS"."DB_LOCATION_URI","THIS"."NAME","THIS"."DB_ID"
> FROM "DBS" "THIS" WHERE "THIS"."NAME" = $1
> DETAIL: parameters: $1 = 'default'
> LOG: execute <unnamed>: SELECT "A0"."PARAM_KEY","A0"."PARAM_VALUE" FROM
> "DATABASE_PARAMS" "A0" WHERE "A0"."DB_ID" = $1 AND "A0"."PARAM_KEY" IS NOT
> NULL
> DETAIL: parameters: $1 = '1'
> LOG: execute S_2: COMMIT
> LOG: execute <unnamed>: SHOW TRANSACTION ISOLATION LEVEL
> LOG: execute S_1: BEGIN
> WARNING: nonstandard use of \\ in a string literal at character 234
> HINT: Use the escape string syntax for backslashes, e.g., E'\\'.
> (standard_conforming_strings = off).
> Would this help ?
> http://mapredit.blogspot.fr/2012/12/hive-drop-table-hangs-postgres-metastore.html
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira