Upgrade/patch fails with 'ORA-00001: unique constraint (SYS.I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST) violated' error in RSA Identity Governance & Lifecycle
Originally Published: 2020-03-10
Last Modified: 2023-12-01
Article Number
Applies To
RSA Version/Condition: 7.0.x, 7.1.x, 7.2.x
Issue
patch.log ($AVEKSA_HOME/wildfly/standalone/log/patch.log):
java.sql.SQLIntegrityConstraintViolationException:
ORA-00001: unique constraint (SYS.I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST) violated
ORA-06512: at line 16
aveksaServer.log ($AVEKSA_HOME/wildfly/standalone/log/aveksaServer.log):
**************************************** Patching has failed ORA-00001: unique constraint (SYS.I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST) violated ORA-06512: at line 16 **************************************** 03/10/2020 12:25:39.012 WARN (ServerService Thread Pool -- 115) [com.aveksa.server.runtime.AveksaSystem] Skipping startup operations because checkDatabase is not clear for startup 03/10/2020 12:25:39.012 WARN (ServerService Thread Pool -- 115) [com.aveksa.server.runtime.AveksaSystem] Is Operation In Progress: false Is Operation Pending: false Is Restart Needed: false Has Errors: true Is OK To Startup: false 03/10/2020 12:25:39.013 INFO (ServerService Thread Pool -- 115) [com.aveksa.server.runtime.AveksaSystem] ******************** Aveksa System Initialization End ******************** 03/10/2020 12:25:39.013 FATAL (ServerService Thread Pool -- 115) [com.aveksa.server.runtime.AveksaSystem] **************************************** Initialization has failed! ORA-00001: unique constraint (SYS.I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST) violated ORA-06512: at line 16 ****************************************
Cause
Resolution
Here is the resolution from the Oracle web site. Please note these commands must be executed as sysdba or the SYS user:
- Purge the old statistics from the history to clear the anomalies. By default, Oracle maintains the history of optimizer statistics up to 31 days.
- Start with purging the statistics history from the recent to the oldest as follows.
- Since the bad data could exist in any date, it is recommended to perform below actions one by one and check whether the drop column is succeeded:
SQL> exec dbms_stats.purge_stats(sysdate - 20); => purge the old statistics history more than 20 days retention. SQL> exec dbms_stats.purge_stats(sysdate - 15); => purge the old statistics history more than 15 days retention. SQL> exec dbms_stats.purge_stats(sysdate - 7); => purge the old statistics history more than 7 days retention. SQL> exec dbms_stats.purge_stats(sysdate - 1); => purge the old statistics history more than 1 day retention. SQL> exec dbms_stats.purge_stats(DBMS_STATS.PURGE_ALL); => purge the complete history of optimizer statistics
Once you can drop a table column, the corrupted data has been purged and you can stop further purging of the historical statistics data.
Related Articles
Patch fails on remote database because execute privilege is not granted to AVDWUSER on SYS.DBMS_LOB in RSA Identity Lifecy… 204Number of Views RSA Identity Governance and Lifecycle - 702 Migration fails with ORA-01720: grant option does not exist for 'SYS.DUAL' 139Number of Views What is the SYS.ORA_TEMP_1_DS_% table sometimes seen in a running query in RSA Identity Governance & Lifecycle 37Number of Views ORA-39070: "Unable to open the log file" error or ORA-06512: at "SYS.DBMS_SYS_ERROR" and "SYS.DBMS_DATAPUMP" errors when b… 280Number of Views ORA-01403 no data found error in Account Data Collectors (ADC) in Step 10/11 in RSA Governance & Lifecycle 50Number of Views
Trending Articles
How to manipulate imported RSA SecurID Software Token(s) on an iPhone or iPad device Reporting on RSA Authentication Manager 8.x users with On-Demand Token, a fixed passcode or a hardware/software token assi… How to Download OTP Token Seed Files from myRSA Anomalix idGenius - SAML Relying Party Configuration - RSA Ready Implementation Guide RSA MFA Agent 2.5 for Microsoft Windows Installation and Administration Guide
Don't see what you're looking for?