Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

Data Archive Reference

Output from piartool -as

  • Last UpdatedJun 29, 2023
  • 4 minute read

Command output from piartool -as lists the following PI Archive subsystem internal counters every five seconds.

Note: For information about other options of the piartool command, see piartool command-line options.

  • Archived Events

    The number of new events written to the archive. This number includes delete and edit events.

  • Out of Order Events

    The number of events in which the event timestamp is older than the last event in the target record.

Excessive out-of-order events can lead to system problems such as excess CPU consumption, excessive disk I/O, and archives filling faster than expected.

  • Events Read

    The number of events read by all applications. For example, if a trending application requests an array of events over a specified time period, Events Read increments for each event returned.

  • Read Operations

    The number of archive read requests. Each archive read request increments this count by one, regardless of the number of events returned.

  • Archive memory cache counters

    PI Archive Subsystem uses a memory cache when handling events that are sent to the archive disk file.

By default, the write cache is flushed to disk at least every 300 seconds (5 minutes). Abrupt system shutdowns, such as power loss, should lose no more than the last 5 minutes of data. You can change this time range using a configurable PITimeout table parameter.

The data archive write cache architecture provides large performance gains over reading and writing directly to disk and the operating system file cache. As with all file cache designs, the disk image is often slightly inconsistent, and therefore archive backup cannot be performed without coordination with PI Archive Subsystem.

  • Cache Record Count

    The number of records in the cache.

  • Cache Records Created

    The number of records created for the cache.

  • Cache Record Memory Reads

    The number of times the cache record memory is read.

  • Cache Clean Count

    The number of records that were removed from the cache. The archive cache contains a finite number of records. Old or low use records are removed from memory to make room for most recently accessed records as needed; they are deleted when unused for a certain length of time.

  • Archive Record Disk Reads

    The number of times PI Archive Subsystem loaded a record from disk to the cache. For example, when a user trends a point in PI ProcessBook, PI Archive Subsystem goes to the cache to retrieve the event data. If the record is not there, PI Archive Subsystem loads the record from disk to the cache.

  • Archive Record Disk Writes

    The number of times a record was written to disk. Record-disk write occurs during the regular cache flush and when the number of unflushed events for a point exceeds the configured maximum.

  • Unflushed Events

    The number of events not yet committed to disk (that is, stored in memory).

  • Unflushed Points

    The number of points with any number of events not yet committed to disk.

  • Primary Archive Number

    An internal identifier that should be ignored. Do not confuse Primary Archive Number with the sequence number of the archive, which is listed by
    piartool -al.

  • Archive Shift Prediction

    The predicted time to the next archive shift, based on the average shift prediction over the last 10 minutes.

This shift prediction differs from the one in piartool -al. The piartool -al figure is calculated at the time the call is made.

Archive Shift Prediction is available as a Windows Performance Counter.

  • Archiving Flag

    The archiving flag indicates that events will be read off the event queue and archived. The values that the archiving flag will return depend on whether you have specified the archive set with the piartool -as command. To optionally specify an archive set, use -hist for historical records, -future for future records, or -arcset N, where N is 0 for historical or 1 for future.

If you have specified the archive set, the archiving flag returns 1 if events are being written to the archive, and 0 if not. The archiving flag is set to 1 when there is a mounted primary archive. If a primary archive is registered but not mounted, such as during an archive shift, the archiving flag value is 0.

If you have not specified an archive set with the piartool -as command, or if you are viewing the archiving flag value in PI SMT Operation > Snapshot and Archive Statistics, the archiving flag records the state of both archive sets, historic and future. In this case, the values returned range from 0 (zero) to 3, as shown in this table.

Value of archiving flag

Meaning of value

3

Both historic and future archive sets are writing to the archives

2

Only the future archive set is writing to the archive

1

Only the historic archive set is writing to the archive

0

Neither historic or future archive sets are writing to the archives

  • Archive Backup Flag

You can view registered archives using piartool -al.

Indicates whether the PI Archive Subsystem is participating in a backup (1) or not (0).

  • Shift or System Backup Flag

    Indicates whether the archive is in shift mode (1) or PI Archive Subsystem is in backup mode (0). Shifts occur automatically or you can force a shift with piartool -fs.

  • Failed Archive Shift Flag

    Indicates whether no potential archive shift exists for a shift change (1). Under normal conditions this flag is 0.

  • Overflow Index Record Count

    Shows the number of index records, which speed up access to overflow records. Index records are created when two overflow records for a point are full and third one is being created. This counter provides a measurement of archive file consumption.

  • Overflow Data Record Count

Shows the number of non-primary data records. Each archive has a primary record for each point. When this record is full, data is written to overflow records. This counter provides a measurement of archive consumption.

  • Archive Loaded Flag

    Indicates whether a valid primary archive is mounted (1) or not (0).

TitleResults for “How to create a CRG?”Also Available in