1. Knowledge Base
  2. Monitoring and Reporting

Backup Stuck in “In Progress”

Monitor page shows backup status as “In Progress” even though the backup is either completed or failed.

This article is for Zmanda Enterprise version 4.x and 5.x

Analysis

This issue can be verified in three steps:

  1. You will find new backups from the same backup set getting completed.

  2. Trying to abort the backup will result in the following error

  3. No backend process for the corresponding backup set and date is active.
    This can be verified using the following command
     # ps -ef | grep "/usr/sbin/amdump --exact-match Cloud2" 

Solution

The first step is to run the "amcleanup" command as the "amandabackup" user. This will remove any backup jobs which are in a hung state.

Note: Running this command will halt any ongoing backups for the target backupset. Ensure there are no active recent backups for the backupset you're fixing before executing.

amcleanup -k Cloud2

Run this command a couple of times till you get this message

amcleanup: no unprocessed logfile to clean up

If the backup is still running, we need to update the database tables to reflect the correct status.

The backup status can be updated by modifying the monitor tables in the ZMC database:

  1. Connect to the ZMC database as the "root" user
    # /opt/zmanda/amanda/bin/mysql ZMC
  2.  Run the following query to find all the backups stuck in In-Progress 
    SELECT backupset_name,backuprun_id,runtype,datetime,status,completed FROM monitor_backuprunsummary INNER JOIN backupsets_backupset ON backupsets_backupset.backupset_id = monitor_backuprunsummary.backupset_id WHERE status='In-Progress';

    A similar output will be displayed

  3.  Update the monitor table rows for the backurun_id you obtained in step 3 using the following queries 

    UPDATE monitor_backuprunsummary SET status='Failed', completed=1 WHERE backuprun_id=28;
    UPDATE monitor_backuprundlestate SET status='Completed' WHERE backuprun_id=28;