hello world!

Matrikon Alarm Manager

  • System Architecture


  • Firewall Requirements
Description From

(Outgoing Port)


(Incoming Port)

Protocol &

Incoming Port

AM Webpage Corporate Users AM Server HTTP Port 80
FTP for Backup Prod AM Server Site FTP Server FTP Port 21,

FTP Data Ports (Depending on site)

SMB for Backup AM Server Site File Server SMB TCP Port 445
For Failure Alert AM Server Email Server TCP Port 25
For Failure Alert Primary A&E Collector,

Secondary A&E Collector

Email Server TCP Port 25
A&E Viewer Client Corporate Users (A&E Viewer Client) AM Server TCP Port 8540,8543
Excel Add-in Corporate Users (Excel) AM Server TCP Port 8542
SQL Communication Corporate Users AM Server TCP Port 1433
AM System Communication AM Server

(A&E Archiver)

Primary A&E Collector,

Secondary A&E Collector

TCP Port 8541
DCOM Communication Primary A&E Collector,

Secondary A&E Collector

Primary Experion OPC Server,
Secondary Experion OPC Server.
TCP Port 135

TCP Port


TCP Alarm Printing Primary Citect Alarm Server,

Secondary Citect Alarm Server

Primary A&E Collector,

Secondary A&E Collector

TCP Port 2070
  • In MAM, there are several log files


  • Collector
    • ECMActivity.log
      • Logs all collector activities
    • ECMData <= This entire folder can be deleted to purge all caches and logs
      • DataCache log
        • The purpose of this datacache is like a buffer. If the archiver channel fails, it will keep on this buffer. So when the Archiver starts back, it will start archiving the ones in the datacache
        • Once data is being archived, the data cache will be deleted. The deletion will be done only when all the data in the file is processed. The file size will not decrease accordingly
        • Once data is full, it will right to a second file
        • Once second file is full, it will overwrite the first file
      • Audit log
        • All messages received from a collector channel will be logged here
        • The logs will fill up to 2 files an then overwrite again
        • Unlike datacache log, it will not be deleted
      • Input
        • Is the position of the ODBC Channel Time

  • Archiver
    • When Archiving is being done, the following indicators are available at the archiver console
      • Total Received Messages
        • The total received messages is calculated by the number of messages in the Collector Cache
      • Archived Messages
      • Unrecognized Messages
        • Messages that are not recognized by the rules builder, i.e. it does not match any of the identifying rules, nor does it fit in any criteria
        • Typically would be gibberish value
        • Appears in Error.dat cache
        • Unrecognized Messages will STILL GO THROUGH the PP Script but it’s data will be totally gibberish and it will not be archived
      • Bad or Failed Messages
        • These messages are messages that are recognized by the rules builder and is eventually processed by the PP Script
        • HOWEVER, it fails to be archived after being processed by the PP Script. Even though message.Archive is set as true. One typical reason may be due to the unrecognized timestamp field
        • It will appear in Error.dat cache
      • Messages Filtered by Script
        • These messages are recognized and it will be processed by the PP Script.
        • Messages set as “ignore” as message type will counted in the Messages Filtered by Script
        • Messages set as Message.Archive=False
        • Duplicate Filtered Messages
        • Note that when the post processing script run, there are Messsage. Duplicate and Message.Archive flag.
          • If either of these flags are set (Message.Archive=False or Message.Duplicate=True) then the message will not be archived.
          • The message.duplicate flag will be set by the duplicate filter before the message is parsed by the PPScript
  • RULES Builder Time Format
  • clip_image004
  • clip_image006
  • clip_image008


  • The Alarm Manager ODBC Channel
    • The easiest way to connect to a Database is to create a windows system DSN. In the ODBC DSN, simply right the DSN Name
    • In the ODBC Channel SQL Statement, one can write a complex query. A&E Collector than convolutes that query into another SQL Select Statement which it uses to put a where clause on the last time stamp. (WHERE TimeStamp > {ts '1970-01-01 10:00:00.000'} ORDER BY TimeStamp)
    • The Polling delay in the ODBC Channel will cause a delay for the channel to initiate its first query after it is enabled. The delay will occur again if the channel is disabled and then enabled back again.
    • It was tested when a query is executed and finished later on (e.g. 5 minutes later), the polling delay will start from the time it finished. This will be a problem for sites wanting to set a delay to poll during off peak hours as the time to execute the query is unknown.

  • Restarting a fresh new archive
    • The entire ECM data folder can be deleted to start a fresh new archive
      • You can also delete individual folders inside ECMdata such as datachache and input folders to restart a fresh new archive


  • Rules Builder
    • The ‘system’ message type is used to indicate a DCS system message. This will not be counted as an alarm as it is of no action for the operator.
    • The ‘Ignore’ message type in rules builder will not be recorded as unrecognized message by the archiver nor will It be recorded as archived message or error message. It will be counted as received Messages and will be counted as Messages Filtered by Script. Avoid using it for error detection
    • The ‘Suppress’ message type is just used as a marker to indicate a tag suppression/alarm disabling activity. Since the latest Matrikon version does not have alarms disabled report anymore, this suppression tag is only useful in the Sequence of events report
    • To delete a rule in the field, simply click on the field and press delete. Sometimes if you scroll down there are values down the field even which even when you press delete it doesn’t delete. Don’t worry these fields are nothing (probably a bug). To know whether a field exists in the XML file click on the field and notice a dotted line surrounding the fields. This means that the fields are not in the rules xml file
  • Post Processing Script
    • Message object
      • Message.TagName
      • Message.Timestamp
      • Message.InputName
      • Message.MessageType
        • Can be Either Acknowledge, Alarm, Ignore, OperatorAction, OperatorMessage, Other, ReturnToNormal, Suppress, System, UnSuppress
      • Message.RawMessage
      • Message.Field(fieldName)
      • Message.FieldCount
        • Returns the number of fields (Read-only). Note: TagName, Timestamp, RawMessage, and MessageType are not included in this count.
      • Message.Archive
      • Message.PrintDebug(text)
        • This will print the specified text to the console. Used for debugging.Note: the text will only appear if the Archiver Service has a console window.
      • Message.Beep(frequency, duration)
        • Will cause the computer to emit a beep at the specified frequency for the specified duration (milliseconds).
      • Message.LaunchApp(appName, commandLine)
        • The Archiver will try to launch the application specified by appName. This can be any windows executable that is accessible from the system PATH, or the full path of the executable. Specify arguments with commandLine. Be careful when launching applications with a user interface. If the Archiver service does not have the "Allow service to interact with desktop" option checked, then the application will be hidden!
    • Any variables declared outside the subrountine is will be a global variable and will retain its value during successive calls of the process_message SUbrountine
    • Any code outside the process_message subroutine is executed only once
    • Message.Suppressed can be assigned as
      • Message.Suppressed = True OR Message.Suppressed = 1
      • Message.Suppressed = False OR Message.Suppressed = 0
      • A Direct SQL query such as “Select 1” result can be automatically assigned to Message.Suppressed
    • When creating an SQL Query, single quotes (‘’) are required for VarChar Datatype. For Bit (Such as the Suppressed Field) and Int (Such as EventID field), quote can be inserted and also be omitted. It makes no difference. Both will yield the same value

  • Database Structure
    • VT_Start points to the time the event occurred
    • VT_End points the time the next alarm starts (Or when the alarm ends). All Alarm, RTnormal, Acknowledge, Suppress and etc will have the same VT_End time which is effectively pointing to the next alarm occurrence. NOTE: NOTE THE RETURN TIME, the next alarm time.

  • Duplicate Filtering
    • Matrikon AM duplicate filter does not work when the Archiver Service is restarted
Open-Plant is a revolutionary Industrial IOT Platform software, used to create and deploy Industrial IT apps/solutions. It is an all-encompassing solution offering both back-end and front-end components i.e. the full stack. From our user's experience, creating and deploying Industrial IT apps became 10x faster and 10x less cost. We serve the mining, energy, oil & gas, construction and manufacturing industry. 


Perth, Australia