Memory metrics missing from Azure dashboard - azure

We've recently started using Azure to host some virtual machines, but I've got problems getting the grips on the available resource monitoring metrics.
When I go to the dashboard for the virtual machine, I have the option to add metrics for several things, but Memory Available is missing:
When reading about how to monitor cloud services, it seems clear that you should have the option to add a metrics for Memory Available. Reading other posts here on Stack Overflow, I see other tools such as MetricsHub mentioned - but I don't think this is what we want, as we don't need any monitoring endpoint, we only want to see memory usage in the Azure dashboard (and apps from the Azure store isn't available to us, since we're on an Enterprise Agreement).
Am I missing something obvious here? What must be done to add memory monitoring to the dashboard?

Cloud Services is not the same as Virtual Machines. When you use cloud services, Azure will provision VMs for you and Azure is able to install monitoring tools that see the amount of available memory. When you create your own VMs Azure can't and shouldn't do that. In other words, with VMs you are on your own. The metrics you do see in the portal are the ones that can be measured from outside the VM.
If you do deploy as a Cloud Service then initially you will only have the same metrics as for the VM. There are several ways you can change this.
The easiest is to go to the configuration for your cloud service in the Management Portal and change the logging level from Minimal to Verbose; That will enable a lot more metrics. Alternatively, you can specify which metrics you want collected in the cloud configuration in your project in Visual Studio. It is also possible to do this in code, though that is not the currently recommended practice, instead use the configuration tool in the cloud project in visual studio.
The key thing to understand about the metrics in Cloud Services is that, whichever way you elect to configure them, they are stored in a standard way in Table Storage and Blob Storage. That means using the Azure Management Portal or the tool in Visual Studio or code, the outcome is the same. This also means that a variety of tools including Cerebrata, Visual Studio and, indeed, the management portal can all read this data.
It is also worth noting that because of the way this works, the configuration can be changed at runtime, usually through the portal but there are other tools and approaches in code.
In my experience, you normally only want to sample your performance metrics every two minutes, but do the log shipping every minute. Also note that you can configure trace logs and IIS logs etc to be available to tools like Visual Studio and Cerebrata. For Cloud Services, it is quite rich functionality but it takes some working with it before you start to "get" it all. Enjoy!

You can monitor memory and other "Guest" level metrics in Azure, here's how:
in Azure, go to your virtual machine, scroll down the settings to Monitoring > Diagnostics Settings
Click to enable Guest level monitoring, it can take a few minutes
Then you can go into Metrics for the VM, or Monitor at the top level:
choose the resource (the VM)
choose Guest in the metric namespace, it will load all the new metrics
choose Memory\Committed bytes or whatever ones you want.
You can then pin to dashboard etc as you would normally

It should be possible to install azure diagnostics on VM using powershell command Set-AzureVMDiagnosticsExtension
http://azure.microsoft.com/en-us/documentation/articles/cloud-services-dotnet-diagnostics/#virtual-machine
or using new management portal
http://feedback.azure.com/forums/231545-diagnostics-and-monitoring/suggestions/5535368-provide-azure-diagnostics-runtime-for-vm-iaas
I've tried to configure it using new portal, I can see the the extension IaaSDiagnostics is installed on VM, but no luck yet with getting the data.

Related

How to use OMS for Azure web app

I want to explore OMS (especially Service Map) for Azure webApps, but it shows following error, "In order to on-board a server to Service Map, the Microsoft Dependency Agent needs to be installed on a server being monitored by OMS. Documentation can be found".
Alos, Microsoft claims that 'Monitor service' is used to view the data across multiple subscriptions, resource group etc. But when I view Metrics, it requires 'Resource Name'. Although comments says, 'select or all resources', but It does not give option to select all.
I think it's too late but here it goes, Application insight is what you will need to get the metrics, Have you looked at it as an option?
OMS, is more useful when you are running stuff on Infrastructure as service resources not on Paas/Saas, I guess because the shared responsibility monitoring etc is different in such environment & PaaS/SaaS should already have means to log, monitor & alert.
Though there is workaround to integrate your app for logging that I am aware of, All you need to do integrate the log analytics for your app service, from there you can setup alerting etc.
Installing agent on shared service would never work out, considering there will be other neighbors using the resources however dedicated instances of app will give you greater flexibility.
Thanks

Can I export my Azure subscription's entire configuration?

Is it possible, using the Azure portal or some other means, to export the subscriptions configuration, for example as an XML file?
I mean things like details of web sites / roles, virtual machines, the size of the machines etc?
Then I could export every day and use a diff tool to check nothing has changed by mistake....
Just thought I'd ask before I write a giant PowerShell script.
I agree this would be a nice feature to have. It's often easier to build out the environment via the portal, but copying that from one tenant (dev) to another (prod) would be much faster and easier if it could be exported to JSON or XML and processed via PowerShell.
Azure Resource manager however does not support resources like Cloud Services, API Management, Mobile Services, Azure Scheduler, Azure Automation, Azure Active Directory, Recovery Services, Media Services, etc. ...
So the summary is - No, there is no such service yet to help you export all your subscriptions configurations.
If you just look for Virtual Machines and Web Sites, then Azure Resource Manager may be in help. But if you look for a complete backup - there is no way to easily achieve this today (2015-03-17).
Probably you could write some Powershell script combining the power of Azure Service Management + Azure Resource Manager, but frankly I am not really sure whether that would also help.

Diagnostics to find out why Azure Web Role doesn't start

I am trying to deploy a large web site to Azure as a Web Role. However, Azure on the Instances tab of the Azure dashboard, it tells me it suffers an error during start up, causing it to restart over and over again.
Where can I find log files that will tell me what specifically is going wrong? The manage.windowsazure.com site doesn't seem to have any.
First, debug on your dev machine. Make sure you deployed the right .cscfg file, you don't have any broken connection strings, you're referencing the right version of the DLLs (the same as Azure's VMs) or are copying newer versions to Azure. If those fail, read this topic on WindowsAzure.com and the topics in this node on MSDN. The Hello World code sample also has a basic demonstration of diagnostics that should be helpful.
The basics of diagnostics in Windows Azure:
Must be manually enabled for each role by importing the Diagnostics module in your ServiceDefinition.csdef file
A storage location needs to be configured for the resulting logs in your ServiceConfiguration.cscfg file, such as the storage emulator, or a Windows Azure Storage account. Depending on the types of logs, they are stored in either blobs or tables.
You can either configure diagnostics collection programmatically or with a file that is read when your role starts and can be updated on-the-fly
You can set up and control how often diagnostics data is downloaded to your storage account (important because transactions/transfer/storage costs money), performance counters, or other metrics you need
There are a series of 4 blog posts at http://blogs.msdn.com/b/kwill/archive/2013/08/09/windows-azure-paas-compute-diagnostics-data.aspx which will walk you through step by step how to troubleshoot a role startup failure including log file locations, etc.

Configuring New Distributed Cache for Azure Websites Preview

UPDATE: Nevermind I've found it. It's not done via the Azure Portal but inside the Azure Project Properties Dialog inside Visual Studio.
Anyone know where the new Distributed Cache Feature (I'm not talking about Azure AppFabric Cache) that Scott mentioned in his post can be configured for a website?
Adding information for those who may be wondering what is it:
Yes "Distributed Cache" is a instance specific feature which can be configured during development time with Windows Azure June SDK, via Role properties in Visual Studio as seen in this screen shot:
This feature is available only for Windows Azure Virtual Machine and roles but not for "Windows Azure websites (FREE) in Shared Mode".
The distribute cache is not available in the Azure Website Free or shared because you are not alone on your instance. It should become possible on a reserved, but still not available. Don't forget that the distribute cache is still in preview, so always evolving.

Web Service bound to Web role in Windows Azure?

I am stuck with the question if a Web Service implemented in Windows Azure have to run in a Web role, or is it possible to have it run in a Worker role ? If so, is there an alternative way to monitor the http-traffic, because a Worker role don't give access to the IIS logs ?
BR/Christer
You can run your web services in a Worker Role via ServiceHost (you can also run them with ServiceHost in a Web Role if you wanted). By default, IIS isn't activated in a Worker Role, which is why you don't have IIS logs.
There are several WCF performance counters you could look at, but you probably need to look at networking performance counters for byte-level details.
EDIT: To address question of how to access performance counters: using Remote Desktop should be reserved for debugging purposes. Instead, it's better to collect performance counters with the Diagnostic Monitor, then publish them to Windows Azure Table storage for external access. See this article for a quick intro to Windows Azure and performance counters. The article shows how to manually query the performance counters (which get published to WADPerformanceCountersTable). You can also view this table through Visual Studio (once you install the Windows Azure tools), or through 3rd-party tools such as Cerebrata Azure Diagnostics Manager.

Resources