我可以捕获性能计数器蔚蓝的Web /辅助角色远程...? [英] Can I capture Performance Counters for an Azure Web/Worker Role remotely...?

查看:149
本文介绍了我可以捕获性能计数器蔚蓝的Web /辅助角色远程...?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道在Azure中webrole和工人角色的性能计数器和诊断的产生。

I am aware of the generation of the Performance Counters and Diagnosis in webrole and worker-role in Azure.


  • 我的问题是我能得到一个偏僻的地方或远程应用程序的性能计数器,因为订阅ID和其他证书(第三方应用程序给性能计数器)。

问题,换句话说,我可以得到性能计数器数据,我使用服务管理API任何托管服务的方式...?

Question in other words, Can I get the Performance Counter Data, the way I use Service Management API for any hosted service...?

- 什么是$ P $需要对配置在服务器做...?以获取CPU数据... ???

What are the pre-configurations required to be done in Server...? to get CPU data...???

推荐答案

以下为性能计数器表属性的描述:

Following is the description of the attributes for Performance counters table:

EventTickCount :存储在日志项记录滴答计数(在UTC)

EventTickCount: Stores the tick count (in UTC) when the log entry was recorded.

DeploymentId :标识部署的

角色:角色名

RoleInstance :角色实例名称

CounterName :计数器的名称

打击城市:性能计数器价值

这里的一个关键是要了解如何有效地查询这个表(和其他诊断表)。一个我们希望从诊断表的事情是为在一定的时间周期获取数据。我们的自然本能会查询时间戳的属性此表。然而,这是一个糟糕的设计的选择,因为您在Azure中表中的数据是在PartitionKey和RowKey索引知道。查询任何其他属性将导致全表扫描当你的表中包含了大量的数据,这将创建一个问题。

One of the key thing here is to understand how to effectively query this table (and other diagnostics table). One of the things we would want from the diagnostics table is to fetch the data for a certain period of time. Our natural instinct would be to query this table on Timestamp attribute. However that's a BAD DESIGN choice because you know in an Azure table the data is indexed on PartitionKey and RowKey. Querying on any other attribute will result in full table scan which will create a problem when your table contains a lot of data.

有关这些日志表的好处是,在收集数据时,点的方式重新preartitionKey值psents的日期/时间。基本上PartitionKey是通过使用DateTime.Ticks的高阶位(UTC)创建的。所以,如果你是为在一定日期/时间范围内提取数据,首先你需要计算的蜱为您范围(UTC),并在它的前面,然后prePEND一个0,并使用这些值您的查询。

The good thing about these logs table is that PartitionKey value in a way represents the date/time when the data point was collected. Basically PartitionKey is created by using higher order bits of DateTime.Ticks (in UTC). So if you were to fetch the data for a certain date/time range, first you would need to calculate the Ticks for your range (in UTC) and then prepend a "0" in front of it and use those values in your query.

如果您正在使用REST API查询,你可以使用语法如下:

If you're querying using REST API, you would use syntax like:

PartitionKey GE'0℃;从日期/时间在滴答UTC>'和PartitionKey乐'0℃,在UTC&GT日期/时间;

PartitionKey ge '0<from date/time ticks in UTC>' and PartitionKey le '0<to date/time in UTC>'.

如果您是在我们的工具云存储工作室,Visual Studio或Azure存储资源管理器查询表存储,您可以使用此语法。

You could use this syntax if you're querying table storage in our tool Cloud Storage Studio, Visual Studio or Azure Storage Explorer.

不幸的是,我没有与存储客户端库太多的经验,但让我一起想办法。可能我会写一篇博客文章了。一旦我这样做,我将张贴链接到我的博客张贴在这里。

Unfortunately I don't have much experience with the Storage Client library but let me work something out. May be I will write a blog post about it. Once I do that, I will post the link to my blog post here.

拉​​夫

这篇关于我可以捕获性能计数器蔚蓝的Web /辅助角色远程...?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆