Alarm and Event Archive Migration

Important: You do not have the latest version of Historian! You are missing out on the newest capabilities and enhanced security. For information on all the latest features, see the Historian product page. For more information on upgrades, contact your GE Digital sales agent or e-mail GE Digital Sales Support. For the most up-to-date documentation, go here.

Backing Up Alarm and Event Data

If you are upgrading to the newest version of Historian and you have already collected alarms, you can migrate the Historical Alarm and Event data after upgrading to latest version of Historian. Alarms are not available for retrieval until they are migrated. New alarms collected with the new version of Historian will be available immediately.

Note: Before migrating alarm and event data, ensure that you have backed up the data.

To migrate your alarms into the new alarm database, you must do a backup of the old alarms and restore them into the new database. The backup can be done before upgrade using the Historian Administrator or it can be done after upgrade using the Proficy Alarm Database Migration Tool on the start menu.

To back up the alarm and event data:

  1. Click the Backup Existing Alarms and Events tab.
  2. In the Time Range section, in the From and To fields, set the start time and end time. You may need to migrate small time periods if you have many alarms. If you need to migrate the alarms in blocks of time, do the oldest alarms first.
  3. In the Database Name field, enter the name of the database from which you have to backup the data. Typically, this will be the same as the SQL Server you are currently using.
  4. Select either windows or SQL server authentication by selecting the Use Windows Authentication or Use SQL Authentication options.
  5. In the User Id and Password fields, enter the login credentials. Be sure to use a user name with permission to connect and backup alarms.
  6. In Backup Folder Path field, give the absolute path, including file name, to store the backed up alarms. For example, c:\temp\March2010.bak. Provide the path to place the backup folder on the local computer and if your SQL server is running on a remote computer, enter a path that exists on the remote computer.
  7. Click the Test Connection button to check that the source database is active and the information is accurate. The Begin Backup button is activated.
  8. Click the Begin Backup button to backup the alarms and when the backup is complete, you will get a count of rows backed up.

Migrating Historical Alarm and Event Data

To make the backed up alarms available for retrieval, you have to write them into the current alarm database.

To migrate Historical Alarms and Events to the latest version of Proficy Historian:

  1. Click the Migrate Alarms and Events Backup tab.
  2. In Backup File Path field, provide the location of the file containing the backup. If your server is running on a remote computer, enter a path that exists on the remote computer.
  3. In the Database section, in the SQL Server Instance Name field, enter the server name. In the Database Name field, enter the name of the database to which you have to migrate the data. Click the Test Connection button to check that the database is active and the information is accurate.
    Note: You can find this information in the registry under: HKEY_LOCAL_MACHINE\SOFTWARE\Intellution, Inc.\iHistorian\Services\AlarmArchiver.
  4. Select either windows or SQL server authentication by selecting Use Windows Authentication or Use SQL Authentication options.
  5. In the User Id and Password fields, enter the login credentials. Be sure to enter an account with permission to restore alarms.
  6. Click the Test Connection button to check that the database is active and the information is accurate.
    The Begin Migration is activated and the alarm data is restored.
  7. Click the Begin Migration button to migrate the data.

Command Line Support for Alarm Migration Tool

If you are using the Alarm Migration Tool using the command line, you can use the following command line switches (case does not matter):

Required Switches

Switches Description
/TASK Command to be executed (for example BACKUP 0r RESTORE).
/SERVER SQLServer Name (for example usgb021).
/DBNAME Database Name (for example AEDatabase).
/SDATETIME mm/dd/yyyy HH:MM:ss format (for example "5/21/2012 10:20:30"). Alarms & Events recorded from this time will be considered. This option is mandatory only when used with BACKUP command.
/EDATETIME mm/dd/yyyy HH:MM:ss format (for example "5/25/2012 10:20:30"). Alarms & Events recorded till this time will be considered. This option is mandatory only when used with BACKUP command.
/BKPPATH Fully qualified path of the .dat file where the backup of the Database will be taken. This switch is mandatory only when used with BACKUP command.
/RSTPATH Fully qualified path of the .dat file from where the Database will be restored. This switch is mandatory only when used with RESTORE command.
/USERNAME User Name (for example sa) used to connect to SQL Server using SQL Authentication. If this switch is not provided then Windows Authentication is used to connect to SQL Server.

Optional Switches

Switches Description
/PWD Password (for example Pr0f1cyhist) Default is empty string (no password is okay, but not recommended for security reasons). If you want the password to be blank, simply skip using this switch.

Examples

BACKUP Operation using SQL Authentication:

Proficy.Historian.AandE.Migration.exe /TASK=Backup /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_plantdatabase /SDateTime="3/9/2013 21:00:00" /EDateTime="3/9/2013 23:59:59" /BKPPATH=C:\temp\PDB_0309.dat /USERNAME=sa /PWD=Pr0f1cyhist

BACKUP Operation using Windows Authentication:

Proficy.Historian.AandE.Migration.exe /TASK=Backup /SERVER=Domain\Node /DBNAME=AEDB /SDateTime="5/10/2012 10:20:30" /EDateTime="6/10/2012 10:20:30" /BKPPATH=E:\DBBkpPath\AEDB_1.dat

RESTORE Operation using SQL Authentication:

Proficy.Historian.AandE.Migration.exe /TASK=Restore /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_AEDatabase /RSTPATH=C:\temp\PDB_0309.dat /USERNAME=sa /PWD=Pr0f1cyhist

RESTORE Operation using Windows Authentication:

Proficy.Historian.AandE.Migration.exe /TASK=RESTORE /SERVER=Domain\Node /DBNAME=AEDB /RSTPATH=E:\DBBkpPath\AEDB_1.dat

Multiple Backups Using a Batch File:

cd C:\Program Files\Proficy\Proficy DataBase

start/b/wait Proficy.Historian.AandE.Migration.exe /TASK=Backup/SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_plantdatabase /SDateTime="3/9/2013 21:00:00" /EDateTime="3/9/2013 23:59:59" /BKPPATH=C:\temp\PDB_0309.dat /USERNAME=sa /PWD=Pr0f1cyhist

start /b /wait Proficy.Historian.AandE.Migration.exe /TASK=Backup /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_plantdatabase /SDateTime="3/10/2013 00:00:00" /EDateTime="3/10/2013 02:00:00" /BKPPATH=C:\temp\PDB_0310_1.dat /USERNAME=sa /PWD=Pr0f1cyhist

start /b /wait Proficy.Historian.AandE.Migration.exe /TASK=Backup /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_plantdatabase /SDateTime="3/10/2013 02:00:00" /EDateTime="3/10/2013 04:00:00" /BKPPATH=C:\temp\PDB_0310_2.dat /USERNAME=sa /PWD=Pr0f1cyhist

Multiple Restores Using a Batch File:

cd C:\Program Files\Proficy\Proficy DataBase

start/b/wait Proficy.Historian.AandE.Migration.exe /TASK=Restore /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_AEDatabase /RSTPATH=C:\temp\PDB_0309.dat /USERNAME=sa /PWD=Pr0f1cyhist

start /b /wait Proficy.Historian.AandE.Migration.exe /TASK=Restore /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_AEDatabase /RSTPATH=C:\temp\PDB_0310_1.dat /USERNAME=sa /PWD=Pr0f1cyhist

start /b /wait Proficy.Historian.AandE.Migration.exe /TASK=Restore /SERVER=CPHIST45\PROFICYHIST /DBNAME=CPHIST45_AEDatabase /RSTPATH=C:\temp\PDB_0310_2.dat /USERNAME=sa /PWD=Pr0f1cyhist
Note: Parameter values with spaces should be enclosed within quotation marks (""). For Example: /BKPPATH="C:\Historian Data\AEDB_Bkp.dat".