Using ihPurgeAlarms.exe to Purge Alarms from the Command Line
The Proficy Historian install program automatically installs an alarm purge utility on your system at install time. The default location for this file is typically: ..\Program Files\Proficy\ProficyHistorian\Server\ihPurgeAlarms.exe.
The ihPurgeAlarms.exe
command takes the following optional arguments. If no arguments are supplied, ihPurgeAlarms
will not purge any alarms.
Parameter | Description |
---|---|
-s serverNodeName | The Proficy Historian node you wish to access archive data on. If the -s is not specified, the program will connect to the local archiver. |
-u Username | The password required to connect to the Proficy Historian archiver. This is an optional parameter. |
-p Password | The password required to connect to the Historian archiver. This is an optional parameter. |
-b Backup File Path | The file path where you want to place the file containing the purged alarms. If the path is not specified, the backup will be placed in the default archive path as specified in the Administrator. |
-z 1 ZIP File | Saves the alarms in a ZIP file format. |
-d Relative Number of Days prior to Current Time | Purge alarms older than this time. For example, to purge alarms older than 7 days old, you would use -d 7 . |
-h Relative Number of Hours prior to Current Time | Purge alarms older than this time. For example, to purge alarms older than 12 hours, you would use -h 12 . |
-m Relative Number of Minutes prior to Current Time | Purge alarms older than this time. For example, to purge alarms older than 360 minutes, you would use -m 360 . |
-sec Relative Number of Seconds prior to Current Time | Purge alarms older than this time. For example, to purge alarms older than 120 seconds, you would use -sec 120 . |
Note:
- Specify the path for saving backup files if you want to back up the alarms before purging. If you do not mention the path for backup files but select the zip the file option, then the backup will be placed in the default archives folder with the endstamp.zip as the file name. To select the zip file option, use
-z 1
in the command line. - Specify the backup folder path name in double quotes such as "C:\\backup\\".
- Alarms will be deleted from current time the relative time prior to current time.