Restoring a backup#

To restore a backup of the server, stop the server and replace the existing files and databases with the backup files and databases.

You can restore the server, and the engine all at once, or you can restore only individual systems.

Note: These instructions are for an engine that you installed through HCL™ Launch. If you extended a different Heat engine, follow the backup and restore instructions from the engine vendor.

Restore a backup of the server#

  1. To restore the server from a backup, follow these steps:
  2. Stop the server.

  3. Copy the server files from the backup to the application data directory, overwriting the current files.

    You must restore the backup files to the same location as the existing files because configuration files include system paths.

  4. Restore the database from the backup.

    Important: You must restore the database from a backup that was taken at the same time as the backup of the application data directory.

  5. Restart the server.

Restore a backup of the engine#

  1. To restore the engine from a backup, follow these steps:
  2. Stop the engine Heat services.

    See ../../com.edt.doc/topics/stop_patterns.md.

  3. Restore the database from the backup.

    The engine MySQL database is installed automatically on the same system as the engine, except in the case of a high-availability installation. In high-availability installations, the engine uses an external MySQL database.

    For example, if you used the mysqldump command to create a backup file that is named engineDBBackup.sql, you can restore the backup by running the following command:

    mysql -u root -ppassw0rd < engineDBBackup.sql

    Attention: This command overwrites existing information in the database with the contents of the backup.

  4. If you backed up the engine configuration files, restore them to the /etc/heat folder.

  5. Start the engine Heat services.

    See ../../com.edt.doc/topics/start_patterns.md.

    The RabbitMQ system that the engine uses is not persistent and therefore does not have any data to restore.

Restore a backup of the engine by using a script#

  1. To restore the engine from a backup that you created from the back up script, follow these steps:
  2. Extract the backup package that you created by running the backup script.

    The backup package is named backup.package.number.tar.gz, where number represents the time of package creation and contains both the contents of your engine and configuration files and the script to restore them. See ../../com.udeploy.install.doc/topics/backup_engine.md#.

  3. To restore the engine, run the following command:

    ./extracted\_location/backup.package.number/restoreengine\_versionEngine.sh

    In this command, extracted_location is the folder where you extracted the compressed backup package and engine_version represents the level of the Heat engine that you restore.