11.14 Messenger

Use this Knowledge Script to use the Windows Messenger service to send a message containing AppManager event information to a specified computer.

By default, the event information includes the computer name of the managed client and the event severity. You can select additional information to include.

You can also construct a custom message to send to recipients.

This script raises an event if you select the custom message format but neglect to enter any text for the custom message body. Under these circumstances, the script continues to execute and uses the standard message format.

The destination computer must be running the Windows Messenger service. To send the message to multiple computers, enter a comma-separated list of computer names.

NOTE:

  • This Knowledge Script is not supported on Windows operating systems later than Windows Server 2003.

  • If you are using this Knowledge Script to send a message from a Windows Server 2003 computer to a Windows NT 4 computer, the Messenger service must be running on both computers.

11.14.1 Setting Parameter Values

Set the following parameters as needed:

Parameter

How to Set It

Event Notification

Event severity -- Action warning

Set the severity level, from 1 to 40, to indicate the importance of an event in which the Messenger job returns a warning. The default is 35 (magenta event indicator).

Event severity -- Action failure

Set the severity level, from 1 to 40, to indicate the importance of an event in which the Messenger job fails. The default is 5 (red event indicator).

Severity Configuration

Minimum event severity for Action

Set the minimum severity level, from 1 to 40, for an event that triggers this Action. The default is 1.

Maximum event severity for Action

Set the maximum severity level, from 1 to 40, for an event that triggers this Action. The default is 40.

Action

List of computers to receive message

Provide a computer name or click the Browse [...] button to select the recipient of the Messenger service message. To send a message to multiple recipients, enter a comma-separated list of computer names. For example: QELAB,PORT1,Chris.

Each specified computer must be running the Messenger service.

Message format

Select whether you want to use the standard message format or create a custom message. The default is Standard.

Use the Standard message format if you want the message text to be generated by the Knowledge Script. Use the Custom message format if you want to create your own message.

Standard Message Options

Include date/timestamp?

Select Yes to include the date and time of the event. The default is unselected.

Include JobID?

Select Yes to include the ID of the Knowledge Script job that raised the event. The default is unselected.

Include agent computer name?

Select Yes to include the name of the computer on which the event was raised. The default is Yes.

Include event severity?

Select Yes to include the event severity. The default is Yes.

Include Knowledge Script name?

Select Yes to include the name of the Knowledge Script that raised the event. The default is unselected.

Include AppManager object name?

Select Yes to include the name of the AppManager object where the event was raised. The default is unselected.

Include AppManager Event ID (only on MS action)?

Select Yes to include the event ID number when the Action is initiated by the AppManager management server. The default is unselected.

Include event detail message?

Select Yes to include the event detail message. The default is unselected.

Custom Message Options

Custom text (can include substitutions)

Provide the text you want to include in your custom message.

You can use the keywords listed below to indicate the information you want to include in the body of your custom message. Add a space before and after keywords to ensure that the keywords display properly.

  • $ShortMsg$ (short event message)

  • $DetailMsg$ (detailed event message)

  • $Time$ (date and time of the event)

  • $JobID$ (ID of the job that raised the event)

  • $MachineName$ (name of the computer where the event was raised)

  • $Severity$ (severity of the event)

  • $KSName$ (name of the Knowledge Script that raised the event)

  • $ObjectName$ (name of the AppManager resource object where the event was raised)

  • $EventID$ (event ID)

For $ShortMsg$ and $DetailMsg$ you can use number and wildcard options to indicate specific portions of the text string to include. For example:

  • $DetailMsg$[5] includes the fifth word of the detailed event message

  • $ShortMsg$[1-5] includes the first through fifth words of the short message event

  • $DetailMsg$[*5] includes the first through fifth words of the detailed event message

  • $ShortMsg$[5*] includes the fifth through last words of the short event message

If you do not enter a word specifier, AppManager returns the entire string.

The following are examples of the types of messages you can construct using these keywords:

  • Event from $MachineName$: The $ShortMsg$[1-3] has failed. The last command was $DetailMsg$[4*].

  • A severity $Severity$ event has occurred! Call the owner of $MachineName$ immediately!

Retry count

Set the number of time this script attempts to send the message. The default is 5.