™

Administrator's Guide

Monitoring Traffic

Traffic Server provides several options for monitoring system performance and analyzing network traffic.

This chapter discusses the following topics:

  • Traffic Server Monitoring Tools
  • Working with Traffic Manager Alarms
  • Viewing Statistics from Traffic Line

Traffic Server Monitoring Tools

Traffic Server provides the following tools to monitor system performance and analyze network traffic:

  • Traffic Server can send email that's triggered by alarms that signal any detected failure conditions; refer to Working with Traffic Manager Alarms.
  • The Traffic Line command-line interface provides an alternative method of viewing Traffic Server performance and network traffic information; refer to Viewing Statistics from Traffic Line.
  • The Traffic Shell command-line tool provides yet another alternative method of viewing Traffic Server performance and network traffic information; refer to Starting Traffic Shell.

Working with Traffic Manager Alarms

Traffic Server signals an alarm when it detects a problem. For example, the space allocated to event logs could be full or Traffic Server may not be able to write to a configuration file.

Configuring Traffic Server to Email Alarms

To configure Traffic Server to send an email to a specific address whenever an alarm occurs, follow the steps below:

  1. In a text editor, open the records.config file located in the Traffic Server config directory.
  2. Set the proxy.config.alarm_email variable to the email address alarms will be routed to.
  3. Save and close the records.config file.
  4. Navigate to the Traffic Server bin directory.
  5. Run the command traffic_line -x to apply the configuration changes.

Using a Script File for Alarms

Alarm messages are built into Traffic Server - you cannot change them. However, you can write a script file to execute certain actions when an alarm is signaled. Traffic Server provides a sample script file named example_alarm_bin.sh in the bin directory; simply modify the file to suit your needs.

Viewing Statistics from Traffic Line

You can use the Traffic Line command-line interface to view statistics about Traffic Server performance and web traffic. In addition to viewing statistics, you can also configure, stop, and restart the Traffic Server system. For additional information, refer to Configuring Traffic Server Using Traffic Line and Traffic Line Commands. You can view specific information about a Traffic Server node or cluster by specifying the variable that corresponds to the statistic you want to see.

To view a statistic:
  1. Log on to a Traffic Server node as the Traffic Server administrator; navigate to the Traffic Server bin directory.
  2. Enter the following command:
    traffic_line -r variable
    where variable is the variable representing the information you want to view. For a list of variables you can specify, refer to Traffic Line Variables.

    For example, the following command displays the document hit rate for the Traffic Server node:
    traffic_line -r proxy.node.http.cache_hit_ratio

    If the Traffic Server bin directory is not in your path, then prepend the Traffic Line command with ./ (for example: ./traffic_line -r variable).
  • Overview
  • Getting Started
  • HTTP Proxy Caching
  • Explicit Proxy Caching
  • Reverse Proxy and HTTP Redirects
  • Hierarchical Caching
  • Configuring the Cache
  • Monitoring Traffic
  • Configuring Traffic Server
  • Security Options
  • Working with Log Files
  • Traffic Line Commands
  • Event Logging Formats
  • Configuration Files
  • Traffic Server Error Messages
  • FAQ and Troubleshooting Tips
  • Traffic Server 管理员指南 (PDF)
Copyright © 2013 The Apache Software Foundation. Licensed under the Apache License, Version 2.0. Apache Traffic Server, Apache, the Apache Traffic Server logo, and the Apache feather logo are trademarks of The Apache Software Foundation.