Restoring the EVS Server

If you have created a backup of the EVS server, follow these steps to restore it.

To perform the restore itself, you can either use the Windows command line or use the MySQL workbench.

  1. Stop the EVS service.
  2. If you have enabled incremental logging:
    1. Restart the MySQL service.
    2. Execute the command mysqladmin flush-logs.
  3. To perform the restore from the Windows command line:
    1. Open a Command Prompt window.
    2. Run the command %MYSQL_HOME%\mysql -u root -v.
    3. When prompted for a password, provide the password for the root user. The default password is vocera.
    4. Type the command \. path, where path is the path to the desired backup file.
  4. To perform the restore from the MySQL workbench:
    1. Open the MySQL workbench. This is included with EVS.
    2. Connect to the EVS database (localhost:3306).
    3. Use Open SQL Script to open the backup file (or type Ctrl+Shift+O).
    4. Run the SQL script.
  5. To optionally perform an incremental restore:
    1. On the drive on which you have installed EVS, go to the evs\backup folder.
    2. Locate all files with prefix evs-bin. whose date is newer than the time of the error or reinstall. Copy these files to a temporary directory.
    3. Run the batch script evs-restore-incremental.bat, passing the location of the temporary directory as its argument. For example, if you have copied files to the C:\vocera\temp\recover folder, run the following command:
      evs-restore-incremental.bat C:\vocera\temp\recover
    4. If the most recent of your incremental recovery files contains transactions that you want to exclude from the start or end, you can modify the restore command in the evs-restore-incremental.bat file to include either of the following:
      • --start-datetime=datetime: Exclude transactions before the time specified in datetime.
      • --stop-datetime=datetime: Exclude transactions after the time specified in datetime.

      For example, to restore transactions prior to 9:00 on April 1, 2017 only, edit the evs-restore-incremental.bat file. Change the line

      for %%i in (".\evs-bin*") do (%MYSQL_HOME%\bin\mysqlbinlog %%i --database=evs >> recovery.sql)

      to

      for %%i in (".\evs-bin*") do (%MYSQL_HOME%\bin\mysqlbinlog %%i --stop-datetime="2017-04-01 09:00:00" --database=evs >> recovery.sql)
  6. Start the EVS service.