pigetmsg command-line options
- Last UpdatedSep 25, 2025
- 4 minute read
- PI System
- PI Server
The following tables list pigetmsg options by option type. For connection options, see Operate PI Data Archive utilities remotely.
Mode options
|
Mode Option |
Description |
|
-f |
Update continuously (refreshing every two seconds). |
|
-i |
Interactive mode (the default mode). Combine with -f for prompts through each page of messages. |
Input options
|
Input Option |
Description |
|
-if file_name |
Read messages in the specified message log file. |
Filter options
pigetmsg filter options valid for group counts with the sum and top options
|
Filter Option (Field) |
Description |
|
-id msg_id |
Retrieve messages with the specified message identification number. (Specify for free-format messages.) |
|
-mc num_msg |
Retrieve no more than the specified number of messages. |
|
-msg text |
Retrieve messages with the specified text. The text must match exactly. To retrieve messages with additional text, include wildcard characters (). For example, specify -msg Consumer* to retrieve messages that start "Consumer" and contain any subsequent text. Specify -msg "*timed out*" to retrieve messages that contain "timed out" any place in the message text. |
|
-ohost name |
Retrieve messages written by processes acting on behalf of users from the specified host name. Without a specified host name, retrieves messages without an originating host, such as those written locally or those written by older clients. |
|
-oosuser name |
Retrieve messages written by processes acting on behalf of the specified user name. |
|
-opiuser identity |
Retrieve messages written by processes acting on behalf of users with the specified PI identity. |
|
-phost name |
Retrieve messages written by processes running on the specified host name. With no specified host name, retrieve messages written by processes running on localhost. |
|
-pid number |
Retrieve messages written by programs with the specified process ID number. |
|
-posuser name |
Retrieve messages written by processes running under the specified user account name. |
|
-ppiuser identity |
Retrieve messages written by processing running under user accounts with the specified PI identity. |
|
-pr name |
Retrieve messages written by specified program name, such as pinetmgr. |
|
-src name |
Retrieve messages written by specified program name, such as pinetmgr, or that contain specified value in src1, src2, or src3 fields. With no program specified, retrieve messages written by any program. |
|
-src1 name |
Retrieve messages with specified value in the src1 field. Values contained in this field vary by the program writing the message. |
|
-src2 name |
Retrieve messages with specified value in the src2 field. Values contained in this field vary by the program writing the message. |
|
-src3 name |
Retrieve messages with specified value in the src3 field. Values contained in this field vary by the program writing the message. |
Filter options not valid
Filter options for pigetmsg that are not valid to group counts with the sum and top options
|
Filter Option |
Description |
|
-cat type |
Retrieve messages that belong to the specified category. |
|
-et time |
Retrieve messages up to the specified end time, entered in PI time format. Beginning with Data Archive 3.4.385, if you specify just -st, then pigetmsg assumes the end time is the current time. |
|
-pri number |
Retrieve messages marked with the specified priority (1-10). |
|
-si |
Retrieve information, warning, error, and critical messages. |
|
-sw |
Retrieve warning, error, and critical messages. |
|
-se |
Retrieve error and critical messages. |
|
-sc |
Retrieve critical messages only. |
|
-st time |
Retrieve messages beginning at the specified start time, entered in PI time format. |
|
-t |
Retrieve last message in the specified time range. Without an end-time specification, retrieve most-recent message. |
Prompting options
|
Prompting Option |
Description |
|
-qb |
Run pigetmsg interactively, prompting for basic options only (start time/end time). |
|
-qa |
Run pigetmsg interactively, prompting for all options. |
Formatting options
|
Formatting Option |
Description |
|
-fb |
Generate binary message-log output. |
|
-fc |
Generate CSV-format output. |
|
-ft |
Generate two-line output (two lines per message). |
|
-fw |
Generate wide-format output (one message per line). |
|
-fx |
Generate XML-format output. |
Output options
|
Output Option |
Description |
|
-m msg_id |
Display the message definition for the specified message ID. Note: Do not combine with other options. |
|
-oa |
Output all message fields (by default, only shows the most common fields). |
|
-of filename |
Output results to the specified file (if no file name specified, use a default). By default, writes to a binary (message log) format. |
|
-ssd num_digits |
Display specified number of digits in subsecond time stamps (for example, 5 for 17-Jul-09 10:23:13.03518). By default, shows no subseconds. |
|
-sum spec |
Display a count of messages. Optionally, include spec to group message counts by a filter option or a time interval:
|
|
-top field |
Display a count of messages grouped by specified filter option and sorted by number of occurrences. The command can group by select pigetmsg filter options. For example, specify -top id to see a count of messages with unique message IDs, sorted by most frequently occurring message ID. |
|
-tz spec |
Override the local time zone settings and display in the zone defined by spec. For example, -tz -5h displays messages in U.S. Eastern Standard Time. |