Restoring Elasticsearch Logs from Backup in Foresight Mobile Platform 23.05 or Later

To restore Elasticsearch logs from backup in Foresight Mobile Platform 23.05 or later:

  1. Make sure that versions of docker client and docker server correspond to 26.1.xx, and versions of docker-compose corresponds to 1.29.xx:

% docker version

% docker-compose -v

If versions of docker client, docker server and docker-compose do not correspond to the specified ones, update them.

  1. Copy the elasticsearch_backup.py and create_elastic_backup_standalone.sh scripts and place them in the folder with the docker-compose.standalone.yml file:

  1. Place the elastic_backup folder with the docker-compose.standalone.yml file. If the backup was created for the general system, elastic_backup will be contained in the standalone_backup_<date and time of backup creation> folder.

  2. Start the elasticsearch_backup.py script using Python 3.6 or later:

python3 elasticsearch_backup.py restore

  1. Check system performance and volume of restored data:

    1. Check cache data volume. If the data volume is not full, delete cache and add it again in the Cache Control subsection.

    2. Reset JWT expiration time for API users and administrators. To do this, change values of the parameters: Expiration Time of JWT Token for API Users, Expiration Time of JWT Token for Administrators, Expiration Time of refresh JWT for API Users and Administrators in the Security subsection.

    3. Add accounts of API users if they were added after creating a backup.

After executing the operations the Elasticsearch logs are restored from the backup.

See also:

Creating a Backup and Restoring System | Creating a Backup of Elasticsearch Logs in Foresight Mobile Platform 23.05 or Later