Merging the indexed data from the LQE2 instance into the LQE1 instance

To ensure that the LQE1 instance contains a complete and accurate data set for reporting, merge the indexed data from the LQE2 instance with the current data on the LQE1 instance. These steps assume that you continue to use the LQE1 instance as the Lifecycle Query Engine server, and not the LQE2 clone.

Before you begin

The disk space is at least three times the current size of the indexes under <JTSInstallDir>\server\conf\lqe or <JTSInstallDir>\server\conf\ldx.

Procedure

  1. Back up both the LQE1 and LQE2 instances. For details, see Backing up and restoring Lifecycle Query Engine and Link Index Provider.

    Backing up the LQE1 instance ensures that you preserve the history in case it is deleted accidentally.

    Backing up the LQE2 instance provides you with the data you need to merge both Lifecycle Query Engine instances.

  2. Stop both Lifecycle Query Engine instances.
  3. In the lqe.properties file of the LQE1 instance, set this Lifecycle Query Engine property: lqe.restore=true.
  4. Overwrite the history of the LQE1 instance (not the new LQE1 backup).
    1. Copy the following folders from the LQE2 backup to the LQE1 instance:
      • Copy /datasets into conf/lqe
      • Copy /metadata into conf/lqe

    2. In the LQE1 instance, delete the following folders, which are subfolders of what you copied.
      • conf/lqe/datasets/history/indexTdb
      • conf/lqe/datasets/history/textIndex
    3. Copy the LQE1 history folders to the datasets folders.
      • Copy conf/lqe/historyTdb to conf/lqe/datasets/history/indexTdb
      • Copy conf/lqe/historyText to conf/lqe/datasets/history/textIndex
  5. Copy lqe.key from LQE2 backup to LQE1.
  6. Set passwords in plain text in dbconnection.properties file.
  7. Update the context root and table names in config_manifest.json file located in the metadata folder so that they match the values for LQE1.

    The config_manifest.json file contains entries that reference the context root of the LQE instance. When you restore data from LQE2 to LQE1, update these entries match the context root of the target instance (LQE1).

    For example, if the original backup was taken from an instance with context root lqe:

    "TABLElqe_sel": "TABLElqe_sel.csv",
    "TABLElqe_selns": "TABLElqe_selns.csv"
    

    If the target instance has context root lqe1, update the entries:

    "TABLElqe1_sel": "TABLElqe1_sel.csv",
    "TABLElqe1_selns": "TABLElqe1_selns.csv"
    

    Also update file names in the metadata directory:

    For example, if the file name is TABLElqe_sel.csv (from LQE2), rename it to TABLElqe1_sel.csv to match the LQE1 context root.

  8. Validate the copied files in LQE1. Check the following:
      • The history/indexTdb and history/textIndex folders are correctly replaced.
      • The renamed files in metadata match the updated context root.
      • The lqe.key from LQE2 is present in LQE1.
      • The dbconnection.properties contains correct plain-text passwords.
      • The config_manifest.json reflects the correct context root and table names.
      • Start LQE1 and check logs for errors.
      • Validate that reports and queries return expected results.

Results

The LQE1 instance now contains fully indexed, up-to-date data. Your work with the LQE2 instance is complete.