• How to monitor server connections, load, and application statistics

    This article provides information about how to use Wowza Streaming Engine™ Manager to monitor the media server and streaming applications. Comprehensive metrics deliver real-time data about CPU and memory usage, connection counts, client players, applications, and network statistics.

    Contents


    Viewing monitoring information
    Metrics that are collected
    Enabling monitoring and statistics
    Getting data from HTTP Providers

    Viewing monitoring information


    Wowza Streaming Engine Manager has the following options available to access data and display historic charts in a browser.

    Home page

    The Home page displays a Connections line chart of connection counts that are updated every 5 seconds. This chart contains up to one hour of data and is updated as new samples are requested. The Usage bar chart displays system-level details about Wowza Streaming Engine and are refreshed along with the connection count graph.



    Server monitoring

    On the Server Monitoring page, the Current Usage bar chart displays current media server metrics, refreshed every 5 seconds, with charts for the stored data. The Connections line chart shows historic connection data. This information is refreshed only on user demand and won't automatically update.



    All times in the web browser are displayed in the user's local time. The media server translates to Coordinated Universal Time (UTC) to get the appropriate data.

    You can specify that data from a specific date/time range be displayed by selecting a predefined date and time range in a list.



    Unless otherwise specified, these selections start from the current time and go backward in time for the appropriate range. For example, last hour shows data from 60 minutes ago to the current time. If the current time is 10:50, the data range is from 9:50 to 10:50.

    Below the date/time range selection are options you can to show the minimum or maximum values, average values, or actual values of the data.

    When you select an hour range and the selected hour occurs no more than 12 hours before the current time, 5-second samples are returned and can be viewed as well. If this criteria is satisfied, you can click the actual option to display the 5-second sample data on top of the currently selected option.

    Each chart allows click-and-drag zooming to highlight areas. This won't increase the chart data resolution beyond what's stored. To highlight a section, place the mouse cursor inside the chart at the desired start point, then click, hold, and drag. When you release the mouse, the highlighted section fills the chart area. A Reset button is available so you can reset the display back to the originally selected range.

    The following charts are available on the Server Monitoring page:

    Current Usage
    Connections
    Network
    Wowza CPU
    Memory
    Total Disk

    Application and virtual host monitoring

    The charts on the Monitoring pages for applications and virtual hosts (VHosts) work the same as the Server monitoring page and use the same metrics.



    To display incoming stream details when streaming to a live application, click the live application name in the contents panel, click Incoming Streams, and then click the stream name (for example, myStream). This loads a details page that includes current connection, uptime, and network throughput information but no historical data charts.



    Metrics that are collected


    Wowza Streaming Engine keeps detailed metrics from various server components. Each application and virtual host (VHost) collects and stores the following metrics:

    • Connection Count by Protocol
    • Bandwidth In
    • Bandwidth Out

    Wowza Streaming Engine itself collects and stores the following metrics:

    • Total Connection Count
    • Bandwidth In
    • Bandwidth Out
    • CPU Usage of the Wowza Streaming Engine server
    • Heap Usage of the Wowza Streaming Engine server
    • Total Memory Used
    • Total Disk Used across all drives

    Wowza Streaming Engine records these metrics every 5 seconds on the per-application, VHost, and server levels. The 5-second samples are then averaged every minute and stored. Up to 12 hours of 5-second samples are kept at any one time. Per-minute averages are cycled--kept for 72 hours and then deleted--on a rolling basis. Hourly averages are computed from the minute data and 31 days of hourly averages are kept. Daily averages are computed from the hourly data and up to 365 days of daily averages are kept. All times are stored in Coordinated Universal Time (UTC) in the database. The raw, fixed-size database files are stored in the [install-dir]/stats folder of the Wowza Streaming Engine installation.

    Enabling monitoring and statistics


    The graphical displays of server and application data are enabled in the Wowza Streaming Engine Manager by default. If they're not showing, you can set an option to display them:

    1. Click the Server tab at the top of the manager page, and then click Server Setup in the contents panel.

    2. On the Server Setup page, click Edit.

    3. Select Enable monitoring and statistics for this server, and then click Save.


    Getting data from HTTP Providers


    You can view statistical data supplied by the following built-in HTTP Providers (found in /conf/VHost.xml in a Web browser:

    HTTPServerInfoXML - (com.wowza.wms.http.HTTPServerInfoXML)
    Returns detailed server and connection information in XML format and is available through administrative port 8086 (http://[wowza-ip-address]:8086/serverinfo).

    HTTPConnectionCountsXML - (com.wowza.wms.http.HTTPConnectionCountsXML)
    Returns detailed connection count information in XML format and is available through administrative port 8086 (http://[wowza-ip-address]:8086/connectioncounts).

    HTTPConnectionInfo - (com.wowza.wms.http.HTTPConnectionInfo)
    Returns detailed connection information in XML format and is available through administrative port 8086 (http://[wowza-ip-address]:8086/connectioninfo).

    Notes:
    • In some browsers, you may not see all of the information or it may not be easy to read, unless you do View > Source.

    • Internet Explorer does the best job of rendering the XML output from these providers because it includes line breaks, indentation, and some colors.

    Source code for customized output

    To build and deploy custom HTTP Providers, use the Wowza IDE.

    If you want customized output, use the source code for the serverinfo HTTP Provider. See How to get detailed server info with an HTTP Provider.

    To get the source code for the connectioncounts HTTP Provider, see How to get connection counts for server, applications, application instances and streams with an HTTP Provider.

    To see how these HTTP Providers are configured for a Wowza media server, look at the "Admin HostPort" settings in [install-dir]/conf/VHost.xml.

    Accessing data from another program

    You can use basic or no authentication to access the statistical data from another program. Open [install-dir]/conf/VHost.xml in a text editor, and then change the AuthenticationMethod in the <HostPort>/<HTTPProvider> section. For example, for the connectioncounts HTTPProvider, set the AuthenticationMethod to admin-basic as in the following code sample, or to none:
    <HTTPProvider>
    	<BaseClass>com.wowza.wms.http.HTTPConnectionCountsXML</BaseClass>
    	<RequestFilters>connectioncounts*</RequestFilters>
    	<AuthenticationMethod>admin-basic</AuthenticationMethod>
    </HTTPProvider>
    If you specify admin-basic authentication, you can add user name and password to the URL:
    http://username:pwd@[wowza-ip-address]:8086/connectioncounts

    Originally Published: 10-02-2010.
    Updated: For Wowza Streaming Engine 4.0.6 on 08-11-2014.

    If you're having problems or want to discuss this article, post in our forum.