Database Reference
In-Depth Information
Another way to collect data from an event log is to use the GetDefaultInitialConiguration
method in the programming code. hen, specify a data source such as WindowsEventLog, and
call the start method of the class DiagnosticMonitor.
To collect data from the crash dump logs, in the programming code, you irst need to ensure
that the project references the Microsoft.WindowsAzure.Diagnostics.dll ile in the programming
code. You then call either the EnableCollection or the EnableCollectionToDirectory method from
the CrashDumps class. hen, you can collect the entire crash dump information or specify a sub-
set of the crash dump information.
To collect diagnostic data from a custom log ile in a local storage resource, you need to add
the LocalResources element into the service deinition ile with following code:
< LocalResources >
  < LocalStorage name = "CustomLogs_Name" sizeInMB = "10"
cleanOnRoleRecycle = "false"/ >
< /LocalResources >
he attribute cleanOnRoleRecycle is used to specify whether the local storage resource should
be wiped clean when a role instance is recycled. In the programming code of your role, include
the reference Microsoft.WindowsAzure.Diagnostics. You can then specify the coniguration of the
Windows Azure diagnostic monitor by creating a DiagnosticMonitorConiguration object. After
you restart the diagnostic monitor, diagnostic data will be collected during the operation.
You can view the collected diagnostic data in Server Explorer of Visual Studio with Windows
Azure Tools preinstalled. Once connected to the Windows Azure storage account, you are able to
view the content stored in the Blob storage and Table storage. You can also view the diagnostic
data stored in the local storage emulator account.
Monitor with Windows Azure Management Portal : he Windows Azure Management
Portal provides status values of the deployments in a cloud service. Status values such as Created,
Ready, and Active are used to indicate the status of a cloud service, deployment, and subscription.
he status values will be displayed in the Management Portal for actions such as creating, updat-
ing, starting, and stopping a deployment. he following activity illustrates the monitoring opera-
tions provided by the Windows Azure Management Portal.
ACTIVITY 12.4 MONITORING WITH WINDOWS
AZURE MANAGEMENT PORTAL
here are two levels of monitoring: minimal monitoring or verbose monitoring. With minimal
monitoring, you can monitor CPU percentage, disk read throughput, disk write throughput,
and data I/O. Minimal monitoring is easy to set and it does not need your storage account for
storing the monitoring data. With verbose monitoring, you can collect additional performance-
related information. You can also analyze application operation-related issues. Verbose monitor-
ing requires a storage account for data storage, data transfer, and storage transactions. he use of
the monitoring tool in the Windows Azure Management Portal requires that Windows Azure
Diagnostics be enabled. he Windows Azure Diagnostics tool is enabled in Visual Studio 2012
by default. In this activity, you are going to use minimal monitoring and verbose monitoring to
accomplish the following monitoring tasks:
 
Search WWH ::




Custom Search