Shohei Okumiya created HIVE-28352:
-------------------------------------

             Summary: Schematool fails to upgradeSchema for dbType=hive
                 Key: HIVE-28352
                 URL: https://issues.apache.org/jira/browse/HIVE-28352
             Project: Hive
          Issue Type: Improvement
          Components: Metastore
    Affects Versions: 4.0.0
            Reporter: Shohei Okumiya
            Assignee: Shohei Okumiya


Some upgrade DDLs are stored with incorrect file names.
{code:java}
$ schematool -metaDbType derby -dbType hive -initSchemaTo 3.0.0 -url 
jdbc:hive2://hive-hiveserver2:10000/default -driver 
org.apache.hive.jdbc.HiveDriver
$ schematool -metaDbType derby -dbType hive -upgradeSchema -url 
jdbc:hive2://hive-hiveserver2:10000/default -driver 
org.apache.hive.jdbc.HiveDriver
...
Completed upgrade-3.0.0-to-3.1.0.hive.sql
Upgrade script upgrade-3.1.0-to-4.0.0-alpha-1.hive.hive.sql
2024-06-27T01:41:46,572 ERROR [main] schematool.MetastoreSchemaTool: Upgrade 
FAILED! Metastore state would be inconsistent !!
Upgrade FAILED! Metastore state would be inconsistent !!
2024-06-27T01:41:46,572 ERROR [main] schematool.MetastoreSchemaTool: Underlying 
cause: java.io.FileNotFoundException : 
/opt/hive/scripts/metastore/upgrade/hive/upgrade-3.1.0-to-4.0.0-alpha-1.hive.hive.sql
 (No such file or directory)
Underlying cause: java.io.FileNotFoundException : 
/opt/hive/scripts/metastore/upgrade/hive/upgrade-3.1.0-to-4.0.0-alpha-1.hive.hive.sql
 (No such file or directory)
2024-06-27T01:41:46,572 ERROR [main] schematool.MetastoreSchemaTool: Use 
--verbose for detailed stacktrace.
Use --verbose for detailed stacktrace.
2024-06-27T01:41:46,573 ERROR [main] schematool.MetastoreSchemaTool: *** 
schemaTool failed ***
*** schemaTool failed *** {code}
 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to