18.4. Log Migration to a New Instance

When a new virtual instance of InCenter is created, perhaps because a new InCenter version has been installed, there may be a need to transfer the old log data to the new instance. This is achieved using the following steps:

  1. Find out the total disk space used by the old log data by running the following InCenter CLI command:

    admin@InCenter:/> log -status 

    Make sure that at least this amount of disk space is available for the new InCenter instance.

  2. Direct log messages to the new InCenter instance by changing the IP address property of the log receiver object on individual nodes.
  3. In the host operating system for the old InCenter instance, run the script backupLogs.sh which can be found in the scripts folder. This will save the old log data to a specific folder. For example:

    $ ./backupLogs.sh /mnt/cloudBackup/opensearch

    Note that an absolute path must be specified as the script parameter in the above command. If this is not done then it can lead to OpenSearch being unable to start. The same problem could occur if the backup script is terminated before it completes.

  4. Move this backup folder for the logs so it is available to the host operating system of the new InCenter instance.
  5. In the host operating system of the new instance, restore the saved log data in the folder by running the script restoreLogs.sh. For example:

    $ ./restoreLogs.sh /mnt/cloudBackup/opensearch

    Note that when either backupLogs.sh or restoreLogs.sh runs, InCenter will not be able to receive log messages for a period of time.

The new InCenter instance will now have all the old log data available to it.