20.13 Sample Analytics Dashboard Snapshot and Restore

This section provides an example of backup and restore of the Analytics Dashboard. This example explains how the Analytics Dashboard data on the SLES machine is backed up and restored to the RHEL machine.

Prerequisites:

  • Analytics server must be installed and must be working on a SLES machine.

  • Analytics Server must have some data to be backed up and restored.

  • Install Python3 or above and requests package on the RHEL machine. Run the following commands to install Python and its packages:

    yum install python3

    pip install requests

Perform the following to back up data from a SLES machine and restore to a RHEL machine:

  1. Run the following command on the Analytics Dashboard server to map the file system:

    chown -R novlwww:novlwww /var/elasticsearch/snapshot/

  2. Run the following command to mount the NFS:

    mount -t nfs 10.71.142.90:/var/elasticsearch/snapshot /var/elasticsearch/snapshot

  3. Verify if the NFS is working by creating a test file and remove the file once the test is complete.

  4. Run the backup script.

    sh /opt/novell/nam/scripts/ELKBackup.sh

  5. Run the following command to create manual snapshot:

    curl -X PUT http://127.0.0.1:9200/_slm/policy/nightly-snapshots/_execute?pretty

  6. Delete the Analytics Server from the Administration Console.

  7. Install Analytics Dashboard on a RHEL machine.

  8. Run the following command on the RHEL machine to map the file system:

    chown -R novlwww:novlwww /var/elasticsearch/snapshot/

  9. Run the following command to mount the NFS:

    mount -t nfs 10.71.142.90:/var/elasticsearch/snapshot /var/elasticsearch/snapshot

  10. Run the restore script.

    sh /opt/novell/nam/scripts/ELKRestore.sh