Retire Script Not Working

Overview

  • Space on the cluster (/opt/data/sensage/) is low. Storage utilization is about 90%.
  • The retire script is not running properly/not retiring old data; Tables with data older than 1 year found.
  • Error while running the atquery command that runs the retire: the atperl command not being found in the PATH.

Solution

Diagnosis

Check the retire script logs for the error mentioned above.

If there is no logging output and the script logs only mention the date when it was executed but not the result of the retire command, add logging statements to the retire script /opt/data/sensage/bin/Retire-SenSage-Data to debug it. Adding to a bash script logging output to a file, of the form

LOGFILE=<path/to/the/log/file>
command1 >> $LOGFILE
command2 >> $LOGFILE

will allow getting all output of the cronjob execution to diagnose the cause of the issue. 

After logging is set, monitor the next execution of the cronjob which runs the script (temporary adjust frequency to run every minute, if needed).

If the log errors confirm that the atperl command is not being found in the PATH, implement the following solution.

 

Solution

Add the correct PATH statement to the script. Run the retire script from the crontab (adjusting frequency to each minute, if needed) to confirm it runs successfully now. After confirmation, re-configure the original crontab frequency for the script to run.

 

Manually retiring data

If you must free some data urgently, you can review the table timestamps with the atview ... tables --timestamps command and retire old tables manually to free some space until the next execution of the retire command. You can also drop unused tables. The retire and droptbl commands and their usage is explained in the Administration Guide in the Product Documentation for SenSage AP.

Comments

0 comments

Please sign in to leave a comment.