The msgadm
command provides an interface to the Avaya IR logger and alerter administrative files.
Synopsis
msgadm [-e] [
-f
[
command_file|-
]
|command
]
Description
Commands to msgadm
can be specified individually on the command line using the msgadm
command, or they can be multiply specified as input from a file or standard input using the -f flag and a file name argument, as in msgadm -f filename
or msgadm -f
for file input and standard input respectively. The -e flag forces msgadm
to write $EOT after completing each operation, resulting in command output to standard out.
Each command may require one or more of the arguments described in the following table:
Argument |
Description |
Comments |
message_ID |
A member of the set of system message IDs that includes all those whose message class is indexed through the systemLog.h file and whose mnemonics appear in a configured log XXX .h file |
|
priority |
A priority tag as defined with the $priority operator in the /vs/spool/log/msgDst.rules file |
To see the list of priority tags configured with the system, enter msgadm priorities |
time |
A non-zero positive integer with unit suffix indicating time in seconds if suffixed by s, minutes if suffixed by m, or hours if suffixed by h |
|
dst |
The set of destination tags defined in the /vs/spool/log/msgDst.rules file through the $destination operator |
To see the list of destination tags, enter msgadm destination. Note that only the latest destination specified in the /vs/spool/log/msgDst.rules file is recognized. |
threshold |
A non-zero positive integer that indicates a threshold value |
|
The following form sets the priority of message_ID to priority if message_ID is already in the msgDst.rules file. If message_ID does not exist, an entry is created with the indicated priority and the default destinations.
msgadm set
message_ID
priority
priority
In the following form, if add is specified and message_ID exists in the msgDst.rules file, a new destination entry is added to the file. If the entry does not exist, a new entry is created with the default destination plus the specified destination. The priority is set to the default priority. If delete is specified, dst is removed from the destination set for message_ID. The log or MASTER_LOG destination cannot be removed from a message.
msgadm [add|delete]
message_ID
destination
dst
The following form sets the threshold window time of threshold message_ID to time. If no threshold structure has been created for message_ID, one is created with a threshold of 100, and threshold message is set to THR01.
msgadm set
message_ID
window
time
The following form adds a threshold / thres_message_ID pair to the thresh.rules file. If no entry for message_ID exists, an entry is created with a threshold window of one hour.
msgadm add
message_ID
threshold
threshold
message
thresh_message_ID
In the following form, the threshold associated with message_ID of threshold value threshold is deleted. If delete is specified and threshold is the last threshold for message_ID, the entire threshold structure is removed for that message.
msgadm delete
message_ID
threshold
threshold
The following form lists all administrative parameters associated with message_ID or all system messages if all is specified.
msgadm display [
message_ID
|all]
The following form outputs the default list of message priorities.
msgadm priorities
The following form outputs the default list of message destinations (since all messages are sent to the lot destination, the lot destination is omitted from the list).
msgadm destinations
The following form outputs the set of threshold messages.
msgadm thresholds
The following form makes all changes made through previous calls to msgadm take affect in the live logger/alerter system. If sync is not used, you must reboot the system to make changes take effect.
msgadm sync
The following form forces msgadm
to read from input_file, or standard in, if the hyphen ( - ) is specified. The expected input is msgadm
command line arguments as defined above. One complete set of command-line arguments is expected per line. Errors in the input result in no changes to the logger/alerter configuration files, regardless of where the error occurred in the input.
msgadm -f [
input_file
|-]
Examples
The following example sets the priority of message VROP003 to critical. The string *C is quoted to protect it from the shell.
msgadm set VROP003 priority '*C'
The following example adds a threshold of 10 with a threshold message of THR001 to the thresholding structure for the VROP003 message. It is assumed that THR001 is a valid message ID.
msgadm add VROP003 threshold 10 message THR001
The following example displays the message administration parameters associated with message TTS009:
msgadm display SPIP001
Message Id: TTS009 (TTS_MGRFAIL)
Message Priority: **
Message Destinations: log|alarm|maint
Flag:
Threshold Period: 1h
Message Thresholds:
Threshold Threshold Message Id
--------- ------------------
1000 THR003 (THRESH_MAJOR)
Action Command:
Message Text:
TTS009 - (TTS_MGRFAIL) Failed to create TTS proxy manager.
Source: %s Reason: %s
The following example shows the use of the file input mechanism. It sets VROP003 to priority None, denoted by a hyphen ( - ), changes its destination from the alarm to the event, and removes its thresholding structures (if any exist). It sets the priority of TSM002 to "*C" (Critical), assuming "*C" is defined in the msgDst.rules file, and makes the changes take effect in the current environment through the sync directive.
message -f - <<!
set VROP003 priority -
delete VROP003 destination alarm
add VROP003 destination event
delete VROP003 threshold 10|
delete VROP003 threshold 100
set TSM002 priority '*C'
sync
!
See also