Spectrum Report Manager Alarm Bucket Table is marked as crashed

book

Article ID: 207487

calendar_today

Updated On:

Products

CA Spectrum

Issue/Introduction

Users may see the below error in the Spectrum Tomcat log indicating there is an issue with the Spectrum Report Manager Database:
 
Caused by: org.springframework.jdbc.UncategorizedSQLException: PreparedStatementCallback; uncategorized SQLException for SQL [SELECT event_ID, time, event_seq, model_key, vardata, type, model_h, domain, event_key FROM alarmbucket15728640_1601794334359 WHERE event_seq BETWEEN ? AND ?  ORDER BY event_seq]; SQL state [HY000]; error code [1194]; Table 'alarmbucket15728640_1601794334359' is marked as crashed and should be repaired; nested exception is java.sql.SQLException: Table 'alarmbucket15728640_1601794334359' is marked as crashed and should be repaired
        at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:84)
        at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:81)
        at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:81)
Caused by: java.sql.SQLException: Table 'alarmbucket15728640_1601794334359' is marked as crashed and should be repaired

Cause

MySQL Database Corruption

Environment

Release : 20.2.x

Component : Spectrum Reporting

Resolution

Below are the commands that can be run to resolve this issue.

1. Login to the reporting database via MySQL.

cd <SPECROOT>/mysql/bin

./mysql.exe -uroot -proot reporting -A     (Windows)

./mysql --defaults-file=../my-spectrum.cnf -uroot -proot reporting -A     (Linux)

2. Run the repair command using the table name from the error above:

repair table alarmbucket15728640_1601794334359

 

Once this is complete, the Spectrum Tomcat Service will need to be restarted.