Question

We are going to create an application which collects information such as processor and memory utilization.

I think we configured storage account correctly. We referred http://www.windowsazure.com/en-us/manage/services/storage/how-to-monitor-a-storage-account/ link. We use PHP SDK and tried to collect performance metrics(cpu usage etc..).
For reading metrics we followed http://azurephp.interoperabilitybridges.com/articles/scaling-php-applications-on-windows-azure-part-i-performance-metrics#h3Section4 example.

we faced some problems when we developing this application.

1.what is role instance id?

define('ROLE_ID', $_SERVER['RoleDeploymentID'] . '/' . $_SERVER['RoleName'] . '/' . $_SERVER['RoleInstanceID']);
I know role deployment id and role name.(I used SUBSCRIPTION ID instead of RoleInstanceID )

2.'WADPerformanceCountersTable' does not exsist

we tried to get performance metrics using above example, “The table specified does not exist” error is displayed.
// Grab all entities from the metrics table $metrics = $table->retrieveEntities('WADPerformanceCountersTable');

we have wasted lot of time.we can get data from $MetricsCapacityBlob table.But we need to get data from WADPerformanceCountersTable.

Are there any examples for php developers? what are the mistakes we made?

Please help me.

Was it helpful?

Solution

If I'm not mistaken, you're actually confusing Windows Azure Diagnostics with Storage Analytics. $MetricsCapacityBlob table is actually part of Storage Analytics while WADPerformanceCountersTable is part of Windows Azure Diagnostics. What you would need to do is enable diagnostics in your roles. You can read more about Windows Azure Diagnostics here: http://msdn.microsoft.com/en-us/library/windowsazure/gg433048.aspx. These two links may also be useful for you:

http://blogs.msdn.com/b/silverlining/archive/2011/09/19/how-to-get-diagnostics-info-for-azure-php-applications-part-1.aspx

http://blogs.msdn.com/b/silverlining/archive/2011/09/22/how-to-get-diagnostics-info-for-azure-php-applications-part-2.aspx

Once the diagnostics is enabled and is working properly, you should be able to see relevant tables in your storage account.

To answer your other question about role instance id, it is basically an id assigned to your role instances (duh!!!). To explain, you have a web role (let's call it MySuperAwesomePhpWebRole) and you run this role in 2 instances). Each instance will get its own id and they will be named MySuperAwesomePhpWebRole_IN_0 and MySuperAwesomePhpWebRole_IN_1.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top