Restore the Data Repository

You can restore the data repository from an existing backup. To restore the data repository, ensure that the database administrator user is part of the sudoers file.
You can restore the data repository from an existing backup. To restore Data Repository, ensure that the database administrator user is part of the sudoers file.
Do not restore a backup of an older
DX NetOps Performance Management
release into a newer environment. The data from the older version might not be fully compatible with schema changes.
Usually, you restore the data repository to the same computer where you backed it up from. However, you
can
restore the data repository to a different computer. The computer to which you restore must be configured in the same way that the computer you backed up the data repository from is configured. In a cluster environment, each computer to which you restore must be configured in the same way that each computer you backed up each data repository node from is configured.
The following configurations must be the same:
  • the IP address
  • the hostname
  • the catalog and data directories
  • the catalog and data directory permissions
  • the Vertica Linux database administrator user credentials
  • the database administrator user account credentials
  • the database user account credentials
Follow these steps:
  1. Stop the data collector hosts that are associated with the data aggregator by logging in to the computers where the data collector is installed as the root user or a sudo user with access to a limited set of commands. Open a command prompt, and then issue the following command based on your configuration and installation:
    • (Red Hat Enterprise Linux (RHEL) 6.x)
      service dcmd stop
      or
      sudo service dcmd stop
    • (RHEL 7.x/8.x, SUSE Linux Enterprise Server (SLES), Oracle Linux (OL))
      systemctl stop dcmd
    The data collector hosts stop.
  2. Stop the data aggregator by doing the following steps:
    1. Log in to the computer where the data aggregator is installed as the root user or a sudo user with access to a limited set of commands.
    2. Do one of the following steps:
      • Stop the Data Aggregator service by issuing the following command based on your installation:
        • (RHEL 6.x)
          service dadaemon stop
        • (RHEL 7.x/8.x, SLES, OL)
          systemctl stop dadaemon
        The data aggregator starts.
      • (Fault-tolerant environment) If the local data aggregator is running, put the data aggregator in maintenance mode ("Maintenance" status) by issuing the following command based on your installation:
        • (RHEL 6.x)
          service dadaemon maintenance
        • (RHEL 7.x/8.x, SLES, or OL)
          installation_directory/scripts/dadaemon maintenance
          • installation_directory
            The installation directory for the data aggregator.
            Default:
            /opt/IMDataAggregator
        The data aggregator status changes to "Ready" and is unavailable for failover.
    The data aggregator stops.
  3. Stop the data repository by doing the following steps:
    1. Log in to the database server you use for the data repository as the database administrator user,
      not
      as the root user.
    2. Open a command prompt, and then issue the following command:
      /opt/vertica/bin/adminTools
      The
      Administration Tools
      dialog opens.
    3. Select
      (4) Stop Database
      .
    4. Press the
      Space
      bar next to the database name, select
      OK
      , and then press the
      Enter
      key on your keyboard.
      You are prompted for the database password.
    5. Enter the database password, and then press the
      Enter
      key on your keyboard.
      The data repository stops.
      If the data repository does not stop, select
      (2) Stop Vertica
      on Host from the
      (7) Advanced Tools Menu
      .
    6. Select
      Exit
      , and then press the
      Enter
      key on your keyboard.
  4. Prepare to restore the data repository backup by doing the following steps:
    1. Log in as the Linux user account for the database administrator user to the database server you use for the data repository.
      When you set up automatic backups of the data repository, you configured the configuration file with a restore point of seven. You can restore the data repository to the most recent backup or to any of the previous seven incremental backups.
    2. Do
      one
      of the following steps:
      • To restore the data repository to the most recent backup, issue the following command:
        /opt/vertica/bin/vbr.py --task restore --config-file
        <configuration_directory_path_filename>
        • configuration_directory_path_filename
          Indicates the filename and directory path of the configuration file you created when you ran the backup configuration procedure. This file is located where you ran the backup utility (/opt/vertica/bin/vbr.py).
        For example:
        /opt/vertica/bin/vbr.py --task restore --config-file /home/vertica/vert-db-production.ini
        In a cluster installation, you can run the restore task from any of the hosts that are participating in the cluster.
        For a list of available restore points, issue the following command:
        /opt/vertica/bin/vbr.py --task listbackup --config-file
        <configuration_directory_path_filename>
      • To restore the data repository to any of the previous seven incremental backups, issue the following command with the following options:
        /opt/vertica/bin/vbr.py --task restore --config-file
        <configuration_directory_path_filename>
        --archive <
        archive_name>
        For example:
        /opt/vertica/bin/vbr.py --task restore --config-file myconfig.ini --archive 20131020_170018
        • configuration_directory_path_filename
          Indicates the filename and directory path of the specific configuration file you want to restore a specific archive from. You created this configuration file when you ran the backup configuration procedure. This file is located where you ran the
          /opt/vertica/bin/vbr.py
          backup utility.
        • archive_name
          Indicates the name of the specific restore point that you want to restore to. Change to the backup directory that the configuration file for the restore point indicates. All of the restore points that are available are listed. Determine the archive name for the restore point that you want to restore to.
        In a cluster installation, you can run the restore task from any of the hosts that are participating in the cluster.
        For a list of available restore points, issue the following command:
        /opt/vertica/bin/vbr.py --task listbackup --config-file configuration_directory_path_filename
  5. Restart the data repository by doing the following steps:
    1. Log in to the computer where the data repository is installed as the database administrator user,
      not
      as the root user.
    2. Open a command prompt, and then issue the following command:
      /opt/vertica/bin/adminTools
      The
      Administration Tools
      dialog opens.
    3. Select
      (3) Start Database
      .
    4. Press the
      Space
      bar on your keyboard next to the database name, select
      OK
      , and then press the
      Enter
      key on your keyboard.
      You are prompted for the database password.
    5. Enter the database password, and then press the
      Enter
      key on your keyboard.
      The data repository starts.
    6. Select
      Exit
      , and then press the
      Enter
      key on your keyboard.
  6. Restart the data aggregator by doing the following steps:
    1. Log in to the data aggregator host as the root user or a sudo user.
    2. Do
      one
      of the following steps:
      • Start the Data Aggregator service by issuing the following command based on your installation:
        • (RHEL 6.x)
          service dadaemon start
        • (RHEL 7.x/8.x, SLES, or OL)
          systemctl start dadaemon
        The data aggregator starts.
      • (Fault-tolerant environment) If the local data aggregator is running, put the data aggregator into maintenance mode ("Maintenance" status) by issuing the following command based on your installation:
        • (RHEL 6.x)
          service dadaemon maintenance
        • (RHEL 7.x/8.x, SLES, or OL)
          <installation_directory>
          /scripts/dadaemon maintenance
          • installation_directory
            The installation directory for the data aggregator.
            Default:
            /opt/IMDataAggregator
        The data aggregator changes to "Maintenance" status and is unavailable for failover.
  7. Restart the data collectors. Log in to each data collector host as the root user or a sudo user, and start the Data Collector service by issuing the following command based on your configuration and installation:
    • (RHEL 6.x)
      service dcmd start
      or
      sudo service dcmd start
    • (RHEL 7.x/8.x, SLES, OL)
      systemctl start dcmd
    The data collectors restarts.
The data repository is restored.