ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

db_optimize.pl script causes ArchMgr crash on SpectroSERVER landscapes

book

Article ID: 236915

calendar_today

Updated On:

Products

CA Spectrum

Issue/Introduction

We enable a cron job for every Saturday morning at 02:30 am to start a db_optimize.pl script, this works fine for most of our landscapes, however on a few landscapes we see that the db_optimize.pl script causes the ddmdb event table to crash when it starts the optimize.  This causes us to have to repair the database for these landscapes before we can start archive manager.

 

From the mysql.out file we can see that the table crashes exactly 2 seconds after the cron job starts the db_optimize.pl script.

 

2022-03-05T02:30:02.283753Z 275 [ERROR] /usr/Spectrum/mysql/bin//mysqld: Table './ddmdb/event' is marked as crashed and last (automatic?) repair failed

Cause

A previous temp file event.TMD existed and was not removed.

Environment

Release : 21.2

Component :Spectrum Events DDMDB

Resolution

As seen in the output of the db_optimize.pl script the temp file was already existing and therefore a new temp file could not be created.

 

Can't create new tempfile: './ddmdb/event.TMD'

 

Once this file was manually removed then the db_optimize.pl script works without any issues.