Packeteer Home Page Choose a PacketGuide version   

 Feedback

 Search

 Index

 Contents

What's New?



 Overviews

 Recommendations

   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   
   

 Reference

 Product Information
 



 

Create an Agent that Monitors a Class Variable

You can create an adaptive response agent to monitor any class measurement variable available in PacketWise. For example, you can monitor application availability (app-availability%), average round trip time (avg-round-trip-time), network delay (network-delay-avg), or packet exchange time (pkt-exchange-time-avg) of a traffic class. See Measurement Variables for a complete list.

In this example, we will create a new agent called Total Delay. This agent will monitor the total-delay-avg measurement variable (average number of milliseconds to complete the class' transactions; includes network delay and server delay) for a specific traffic class. When the class' total delay exceeds a predefined threshold, the adaptive response feature will alert you that a threshold has been exceeded. The standard alert is a red indicator on the info tab (PacketWise) or configuration tab (PolicyCenter). In addition, you can have an email, SNMP trap, or syslog message sent when the red threshold is crossed; this method requires that you create an action file — a text file of PacketWise commands. The action file can include any CLI command that can run without additional user input. See Action File Overviews for more information.

In order to create agents, the adaptive response feature must be enabled.

Create a New Agent

To create an agent for a class measurement variable:

  1. On the setup tab, click the Adaptive Response Settings link.

  2. Click add. The Add Agent Entry window will open.

  3. Click the create a new agent from this agent template drop-down list, and choose Class ME Variables.

  4. Enter a unique identifying name for the new agent in the Name field, for example Citrix Delay.

  5. Click OK and Edit Parms. This will open the Edit Agent Entry window where you can define the parameter values for your new agent.

  6. In the ClassName field, enter the name of the class to be monitored (for example, Inbound/Citrix).

  7. In the MeVariableName field, enter the measurement variable to be monitored (total-delay-avg). For a complete list of measurement variables you can use, see Measurement Variables; you can select any variable in the Common and Class categories.

  8. Specify the threshold values:

    RedThreshold — The value at which the status of the agent turns red, and a red action file is triggered, if present. For a Total Delay agent, this number represents the average delay in milliseconds. For instance, if the RedThreshold is set to 500, the agent's status will change to red when the class' average network and server delay is over 500 ms in the MeDuration (see step 11 below).

    GreenThreshold — The value at which the status of the agent turns green, and a green action file is triggered, if present. For instance, if the GreenThreshold is set to 300, the agent's status will be green when the average delay is less than 300 ms in the MeDuration.

  9. If desired, change the values for GreenOperator and/or RedOperator.

    In this example, the values for GreenOperator (LT—less than) and RedOperator (GT— greater than) are appropriate. This agent will have a red status when the current value of the measurement variable is greater than (GT) the RedThreshold value and a green status when the current value is less than (LT) the GreenThreshold value. You may want to change the values to GTE (greater than or equal to) and LTE (less than or equal to).

  10. If desired, change the evaluation interval, in minutes (how often the agent should measure its target.)

  11. Specify the MeDuration, the period of time over which measurements will be looked at.

    The MeDuration can be different from the evaluation interval. For example, suppose you set the evaluation interval to 5 minutes and the MeDuration to 60 minutes. The agent will look at the last hour of measurement data every five minutes to see if the red threshold has been exceeded. At 12:00, the agent would analyze data collected between 11:00 and 12:00; at 12:05, the agent would analyze data collected between 11:05 and 12:05; and so forth.

  12. Click OK to save your changes.

After creating the agent, you will want to monitor it to see if the average network and server delay in the class was excessive.

Check the Agent Status

To check the status of the Total Delay agent:

  1. Click the info tab. The PacketShaper’s info tab shows an icon for each agent category, and a colored status indicator for each. The Total Delay agent is in the User Event Emulation category (the last one).

  2. To see the status of each individual agent in the User Event Emulation category, hover your mouse over the colored status indicator, as shown below.



  3. In the pop-up window, locate the Total Delay agent that you defined. The value (for example, 1970) indicates the number of milliseconds of the class' average network and server delay during the MeDuration.

    What color is its status indicator?

    Green — During the MeDuration, delay in the class was at an acceptable level (less than the green threshold).
    Yellow — During the MeDuration, the score (the value of the measurement variable) was between the red and green thresholds.
    Red — During the MeDuration, delay in the class was at an unacceptable level (more than the red threshold). If the status indicator is red, you should look at the incident report for details.

    If the agent has ever changed status (from green/yellow to red or from red/yellow to green, a report icon with a link to a detailed report will be available for that agent.

  4. If there is a report for the Total Delay agent, click the report icon. The incident report appears in a separate browser window.


Create an Action File that Sends an Email Notification

If you would like to be notified by email when a class' delay is excessive (that is, above the red threshold), you can create a command file that contains a single line: the send email command. By designating this command file as the red action file, an email will be sent when the red threshold is crossed.

Note: In order to send email notification, you must configure an SMTP server in PacketWise.

To create an action file that sends an email notification:

1. If the info tab is currently displayed, click the Settings link; otherwise, go to the setup tab and click the Adaptive Response Settings link.

2. Click the edit button next to the Total Delay agent.

3. Click the browse files button. The File Browser window opens and shows the contents of the 9.258/agent/cmd directory (where action files need to be stored).

4. Click the new cmd file button. A command file window opens.

5. In the File Name field, enter a unique name for your action file up to eight characters long, including 0-9, a-z, AZ, -,_, and . (period). Spaces are not allowed. Example: appdelay

6. In the Contents area, enter the following commands:

#Title: red action file for Total Delay agent
send email <address> "<subject>" ["<body>"]


where <address> is the email address of the recipient. For example:

send email raltman@test.com "Citrix is too slow" "The average delay (server plus network) for Inbound/Citrix was at an unacceptable level."

Note: If you want to send an email notification to more than one recipient, repeat the send email command for each email address.

Alternatively, you can include the variables for the agent name ($agentname), class name ($class-id), value of the measurement variable ($me-value), and the red threshold ($RedThreshold) in the <subject> or <body>, as the following example shows:

send email raltman@test.com "$agentname agent" "The average delay (server plus network) of the $class-id class was $me-value ms. This is over the red threshold ($RedThreshold ms). Go to the info tab to view the report for the $agentname agent."

When the message is sent, the body of the email message would look something like this:

The average delay (server plus network) of the Inbound/Citrix class was 70 ms. This is over the red threshold (60 ms). Go to the info tab to view the report for the Citrix Delay agent.

7. Click save.

8. Enter the name of your action file in the Red Action File field (for example, appdelay.cmd).

9. Click OK.

After the next evaluation interval, an email will be sent if and when the agent's red threshold is crossed. If you like, you can create a green action file to notify you when the Total Delay agent returns to a green status.

 


 

 

PacketGuide™ for PacketWise® 8.1