Hdbsetup error ORA-00959: tablespace 'HARVESTINDEX' does not exist
search cancel

Hdbsetup error ORA-00959: tablespace 'HARVESTINDEX' does not exist

book

Article ID: 262535

calendar_today

Updated On:

Products

CA Harvest Software Change Manager

Issue/Introduction

When upgrading Harvest to the latest version, the software installation succeeds but the database upgrade fails.  Hdbsetup returns this error message:

"Error updating schema.  Check log updateschema.log for error"

And the updateschema.log file returns this error:

2023/03/22 14:31:16 E03020003: Database error [Oracle][ODBC][Ora]ORA-00959: tablespace 'HARVESTINDEX' does not exist

SQLSTATE=S1000 .

Environment

Release : 14.0

Cause

When Harvest installs its database to an Oracle DBMS, by default, it sets up three tablespaces with the names HARVESTMETA, HARVESTINDEX, and HARVESTBLOB.

This error message tells us that Hdbsetup cannot find an Oracle tablespace named HARVESTINDEX.  

Logging into SQL Plus, we can get a list of the names of the tablespaces available to the harvest user:

This explains why hdbsetup could not find the HARVESTINDEX tablespace.  The DBA has renamed the Harvest tablespaces according to the naming standards he or the company has chosen.

 

 

Resolution

We must configure Harvest so that it can find the tablespaces it needs using the new tablespace names.  We do this by adding the following lines to the hserver.arg file:

-harvestindex=myscmindex
-harvestmeta=myscmmeta
-harvestblob=myscmblob

We will also need to complete one of the following two options:

  • The safest choice, if this is possible is to restore the database from the backup that was prepared immediately before the upgrade began.
  • The other way is to review the previous updateschema.log file to find out what steps completed successfully before the error hapened.  Then, login to SQL Plus again and “undo” that change to restore the database to its pre-upgrade state.

After completing this change, restart Hdbsetup and try the “UR” option again.

This time, the Upgrade Repository step succeeded.

And checking the updateschema.log we see a much better result:

Additional Information

It is possible when you encounter this error with HARVESTINDEX tablespace name that the database schema is left in a state of partial completion.  If this happens, subsequent runs of hdbsetup UR option will fail as well for various reasons.  In this situation, the simplest solution is to restore your Harvest database from the backup that was made just before upgrading, and starting the database schema upgrade again from there.