This article is for Zmanda Recovery Manager For MySQL (ZRM)
CAUTION: Please note that canceling a restore job might leave the databases in an inconsistent state if you are restoring to original location.
Use this procedure only if the cancel button in the ZRM Restore Restore page does not work. Please follow these steps to stop a restore job as “root” user on the ZRM server:
- Check for “zmc_launcher” process(es)
pgrep -f "zmc_launcher" -l
- Kill all “zmc_launcher” process(es) if all are related to the restore
pkill -9 "zmc_launcher"
- Check for “mysql-zrm-restore-wrapper” process(es)
pgrep -f "mysql-zrm-restore-wrapper" -l
- Kill all “mysql-zrm-restore-wrapper” process(es) if all are related to the restore
pkill -9 "mysql-zrm-restore-wrapper"
- Check for “mysql-zrm-restore” process(es)
pgrep -f "mysql-zrm-restore" -l
- Kill all running “mysql-zrm-restore” process(es) if all are related to the restore
pkill -9 "mysql-zrm-restore"
- Remove PID file for restore run from backup set’s configuration directory
rm /etc/mysql-zrm/<backup set name>/.mysql-zrm.pid
- Run below to clean up ZMC
- Please refresh the ZMC Restore Restore page.
If ZMC still reports that the restore job is still running or in cancelling state, do the following:
- Obtain the restore job task id with the below MySQL query were <backup-set> is the name of your backup-set
# /opt/zmanda/zrm/mysql/bin/mysql -uroot -pzmcdb-admin zmc -e "selectmax(task_id) from task_management where task_name='Restore' and configuration_id =(SELECT configuration_id FROM configurations WHERE configuration_name = '<backup-set>')";
- Use the task_id returned in the above query where it says <task_id> in the below query to update the restore task in ZMC's task table:
# /opt/zmanda/zrm/mysql/bin/mysql -uroot -pzmcdb-admin zmc -e "UPDATE task_management SET status='Cancelled',output='Cancelled forcefully' where task_id=<task_id>";
- On the client machine, the restore processes will terminate automatically if the connection is broken with server. As a precaution we can check for and kill any processes still running on the client machine as well:
# pgrep -f "mysql-zrm" -lif the returned process(es) is related to the restore and not a backup, it may be terminated:
# pkill -9 "mysql-zrm" # /etc/init.d/xinet.d restart