Skip to main content
NetApp Stage KB

OnCommand Insight inline upgrade or restore of backup from a previous version to 7.3.11 shows an error in the upgrade.log, error: "Duplicate entry '6' for key 'system_alert_config.PRIMARY'"

Views:
Visibility:
Public
Votes:
0
Category:
oncommand-insight
Specialty:
oci
Last Updated:

Applies to

OnCommand Insight 7.3.11

Issue

After performing an inline upgrade of OnCommand Insight (OCI) to 7.3.11 or restoring a database backup from a previous version to a 7.3.11 instance, the application appears to work fine, but an error in the upgrade.log is observed.

Further review shows that the database schema upgrade was not completed, which is indicated by the following symptoms:

  • When navigating to Admin -> System Alerts in the web UI, there is no "Duplicate WWN detected" system alert present
  • When navigating to https://<OCI_SERVER_IP>/uiserver/#admin/advancedTroubleshooting/tools, there is no option PHONE_HOME_TIMEZONE_SHIFT_HOURS option present
  • Review of the upgrade.log file reveals an error during the schema upgrade process

2021-05-07 00:13:12,363 ERROR [main] UpgradeAll (UpgradeAll.java:347) - Failed to inline upgrade schema Failed to restore 
com.onaro.sanscreen.upgrade.UpgraderException: Failed to restore 
    at com.onaro.sanscreen.upgrade.UpgradeRunner.restore(UpgradeRunner.java:1423) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeAll.inlineUpgradeSchema(UpgradeAll.java:345) [upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeAll.main(UpgradeAll.java:773) [upgrade.jar:?]
Caused by: com.onaro.sanscreen.upgrade.UpgraderException: Failed to executeUpdateEx:  INSERT INTO sanscreen.system_alert_config VALUES (6, '6', 'Duplicate WWN detected', 'CRITICAl', '', '259200', 0, 0);
Reason: Duplicate entry '6' for key 'system_alert_config.PRIMARY'
    at com.onaro.sanscreen.upgrade.UpgradeRunner$UpgraderEntry.run(UpgradeRunner.java:2084) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.run(UpgradeRunner.java:1622) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.restore(UpgradeRunner.java:1406) ~[upgrade.jar:?]
    ... 2 more
Caused by: com.netapp.oci.platform.common.table.TableException: Failed to executeUpdateEx:  INSERT INTO sanscreen.system_alert_config VALUES (6, '6', 'Duplicate WWN detected', 'CRITICAl', '', '259200', 0, 0);
Reason: Duplicate entry '6' for key 'system_alert_config.PRIMARY'
    at com.netapp.oci.platform.common.table.PreparedStatementWrapper.executeUpdateEx(PreparedStatementWrapper.java:341) ~[serverbase-common.jar:?]
    at com.netapp.oci.platform.common.db.SqlFile.executeFile(SqlFile.java:44) ~[serverbase-common.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner$UpgraderEntry.run(UpgradeRunner.java:2081) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.run(UpgradeRunner.java:1622) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.restore(UpgradeRunner.java:1406) ~[upgrade.jar:?]
    ... 2 more
Caused by: java.sql.SQLIntegrityConstraintViolationException: Duplicate entry '6' for key 'system_alert_config.PRIMARY'
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:117) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:953) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1092) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1040) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeLargeUpdate(ClientPreparedStatement.java:1347) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdate(ClientPreparedStatement.java:1025) ~[mysql-connector-java-commercial.jar:8.0.22]
    at com.netapp.oci.platform.common.table.PreparedStatementWrapper.executeUpdateEx(PreparedStatementWrapper.java:336) ~[serverbase-common.jar:?]
    at com.netapp.oci.platform.common.db.SqlFile.executeFile(SqlFile.java:44) ~[serverbase-common.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner$UpgraderEntry.run(UpgradeRunner.java:2081) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.run(UpgradeRunner.java:1622) ~[upgrade.jar:?]
    at com.onaro.sanscreen.upgrade.UpgradeRunner.restore(UpgradeRunner.java:1406) ~[upgrade.jar:?]
    ... 2 more

 

Sign in to view the entire content of this KB article.

New to NetApp?

Learn more about our award-winning Support

NetApp provides no representations or warranties regarding the accuracy or reliability or serviceability of any information or recommendations provided in this publication or with respect to any results that may be obtained by the use of the information or observance of any recommendations provided herein. The information in this document is distributed AS IS and the use of this information or the implementation of any recommendations or techniques herein is a customer's responsibility and depends on the customer's ability to evaluate and integrate them into the customer's operational environment. This document and the information contained herein may be used solely in connection with the NetApp products discussed in this document.
e4105919-b9d2-4542-8ccf-afb7ae78a316