Skip to content

Use cases for Storages utility#

The Storages utility can be used for updating or downgrading, or for installing from scratch.

It is recommended to create backups before any actions related to updating or downgrading. See recommendations for creating backups and useful links in the update manual.

Example commands for updating and installing from scratch are provided in the corresponding documents. A downgrade is actually no different from an update.

The sections below provide general procedures for performing these tasks.

Launch from scratch#

The general procedure for installing from scratch is as follows:

  1. Launch and configure PostgreSQL/Oracle and InfluxDB databases — create users, configure rights, etc. (see the "Databases" section in the administrator manual).
  2. Compile the VLMatch library for a user version of the PostgeSQL or Oracle database (see the "Databases" section in the administrator manual). The Storages utility automatically adds the VLMatch function to the Faces and Events databases during the database environment preparation phase.
  3. Correctly fill out the Storages configuration, indicating all the necessary data — database addresses and authentication data, S3 connection settings (if necessary), bucket addresses, etc.
  4. Prepare the environment using the prepare command.
  5. Make sure that the environment of the version of interest has been successfully prepared using the check command.
  6. Correctly fill in user settings for services (connection to services, databases, etc.) in one of the following ways:
    • Execute the command load_dump, loading a dump file with user settings *
    • Configure and launch the Configurator service, specifying user settings in it.
    • Fill in the service configuration files, specifying user settings in them.
  7. Launch LUNA PLATFORM services.

* you can edit the full luna_platform_<version>_dump.json dump file included in the distribution package, or use a custom dump file (see example of a custom dump file platform_settings.json included in the distribution package). See the "Configurator service" section in the administrator manual for more information about dumps.

Upgrade/downgrade#

The general procedure for upgrading or downgrading is as follows:

  1. Correctly fill out the Storages configuration, indicating all the necessary data — database addresses and authentication data, S3 connection settings (if necessary), bucket addresses, etc.
  2. Make sure that Storages supports preparing the environment for LUNA PLATFORM of the version you are interested in using the list command.
  3. Check the current LUNA PLATFORM environment using the check command.
  4. Configure the behavior of services during environment preparation
  5. Prepare the environment using the prepare command.
  6. Make sure that the environment of the version of interest has been successfully prepared using the check command.
  7. Update user settings for services (connection to services, databases, etc.) in one of the following ways (optional):
    • Execute the command load_dump, loading a dump file with user settings *
    • Configure and launch the Configurator service, specifying user settings in it.
    • Fill in the service configuration files, specifying user settings in them.
  8. Launch the new version of LUNA PLATFORM services.

* you can edit the full luna_platform_<version>_dump.json dump file included in the distribution package, or use a custom dump file (see example of a custom dump file platform_settings.json included in the distribution package). See the "Configurator service" section in the administrator manual for more information about dumps.

Recommendations services behavior during environment preparation#

When preparing your environment, it is important to carefully plan the impact on services that use databases.

Below are recommendations for managing services in various migration scenarios.

  • Load reduction: Try to reduce the number of requests to a minimum during environment preparation. This will help reduce the likelihood of conflicts and data integrity issues.

  • Restricted Access: Consider temporarily restricting access to services to avoid inconsistent changes during migration.

  • Stopping services: Consider stopping services that actively interact with the database. This can help reduce potential conflicts and simplify the migration process.

  • Caution: If you leave the service running during migration, be prepared for possible delays in the operation of LUNA PLATFORM.

The final decision on how to manage services should be made based on the specific requirements of your system and business processes.