Restoring from a backup
Restore an instance of an application from a backup file on the same system, or restore from a backup file to duplicate an instance on a new, similarly configured deployment.
If you are restoring from a backup that was created on another system, copy the backup archive file to the target system.
Restoring using the browser interface:
- Log in to the Control Center browser interface.
- In the Applications table, identify the name of the application instance.
-
Stop the instance and verify that its subservices are stopped.
- In the Actions column of the Applications table, click Stop.
- In the Stop Service dialog box, click Stop Service and Children.
- In the Applications column of the Applications table, click the name of the stopped instance, and then scroll down to the Services table to verify that all services are stopped.
Because snapshots are loaded to disk, during a restore you are not required to stop services while the file is loaded. Though the restore will not succeed, the snapshot and images are available for you to manually rollback each application.
-
Click the Backup / Restore tab.
- Beside the backup file that you want to use to restore your application, click Restore Backup. Confirm your selection by clicking Restore.
- When the restore is finished, click the Applications tab, then click Start beside the instance you just restored.
- Review and if necessary, define IP assignments.
- Click Applications and then click the application instance.
- Review the IP Assignments table. If all services have an IP assignment, no action is required.
- For any service that does not have an automatic IP assignment, click Assign, choose an IP, and then click Assign IP.
Restoring using the CLI:
-
Log in to the Control Center master as root or as a user with serviced CLI privileges.
-
Identify the name of the application instance to be restored with the
serviced service status
command. -
Stop the service if it is running with the
serviced service stop $SERVICEDID
command. In the case of the Resource Manager application, the command would beserviced service stop Zenoss.resmgr
. -
Restore the backup file with the
serviced restore
command. For a backup file namedbackup-2019-01-29-232324.tgz
located in the default /opt/serviced/var/backups/ directory, the command would beserviced restore /opt/serviced/var/backups/backup-2019-01-29-232324.tgz
. -
A successful restore will print nothing to stdout. Detailed messaging can be found in the serviced journal on the Control Center master. The format in that case should look like the following:
time="2019-01-30T16:33:49Z" level=info msg="Completed Restoring from Backup" action=restore backupfile="/opt/serviced/var/backups/backup-2019-01-29-232324.tgz" elapsed=223.894515sec
-
Start the service with the
serviced service start $SERVICEID
command. In the case of the Resource Manager application, the command would beserviced service start Zenoss.resmgr.