We're trying to get the cpu percentage,disk read throughput,etc programmatically using powershell commands for metrics in azure but we are not able to get any of the commands according to new release.
First of all are you trying to get performance details from Web/Worker Role or New preview release of Windows Azure Virtual Machines?
With Windows Azure Virtual Machine:
You have full access to your Azure VM and configure it the way you would do in any remote VM and the get the performance data out of it. With Windows Azure Virtual Machine if you want to get Performance data from Powershell you would need to do the following:
Configure to Azure VM to have PowerShell Remote Access
Configure Azure VM port settings so you can connect from on-premise machine (this is must and you should know that open port will open connection to VM outside)
Configure Azure VM to collect performance data
Connect from your on-premise machine using PowerShell and collect performance data
You can find several resources on Internet to do above task.
With Web/Worker Role:
Even when you are using new Powershell cmdlets with Windows Azure, older commands are still accessible and working as expected. To get Performance metrics from Azure Here are some resources for your to try:
Windows Azure Diagnostics and PowerShell – Performance Counters:
Part 1 | Part 2
How To Easily Enable Windows Azure
Diagnostics Remotely
Related
can anyone brief me about difference between both? Points that I am expecting in answers
can we install Software
Who is the owner
Can I access my local files and software into cloud machine?
any addons from your side will be more than helpful!
Azure Virtual Machine
An Azure VM gives you the flexibility of virtualization without having
to buy and maintain the physical hardware that runs it. However, you
still need to maintain the VM by performing tasks, such as
configuring, patching, and installing the software that runs on it.
We can install the applications in Azure VM. Use Set-AzVMExtension in PowerShell to install the Custom Script Extension.
To know more in detail, please refer below link:
Tutorial - Install applications on a Windows VM in Azure - Azure Virtual Machines | Microsoft Docs.
By default, the users who created the VM with Owner or Contributor roles are considered VM owners.
To know more in detail, please refer below link:
VM Owner Detection for Azure (commvault.com).
It is possible to access local files in Azure VM.
Azure Windows Virtual Desktop
Windows Virtual Desktop (WVD) is an Azure service that, combined with appropriate licenses, services, and resources, delivers a complete
virtualized multi-user Windows 10 (or a single-user Windows 7)
experience together with Office 365 ProPlus. WVD includes centralized
management and monitoring; system administrators can quickly deploy and manage desktops, apps, and Windows servers in the Azure Cloud.
We can install the applications in Azure Windows Virtual Desktop.
To know more in detail, please refer below link:
https://www.rebeladmin.com/2020/07/step-step-guide-publish-applications-using-windows-virtual-desktop-spring-2020-release/
Azure Windows Virtual Desktop doesn't have a specific Owner role. You can use the general Owner role for the service objects.
I want to give access to somebody to a virtual machine on Azure (with the RDP connection file) and let him start/stop the VM but without giving him access to the Azure Portal account.
Is there a (simple) way to start/stop virtual machine on Azure without having to access the portal ? By "simple" I mean something that you don't need to run some line code and that can be as easy as opening a RDP file.
Alternatively, is there a way not to be billed of a running (but idle) virtual machine ?
You can use a Powershell script to start/stop the VM.
No you will be billed for the stopped VMs also as long as you have checked them out.
For your requirement, I think the best way is to use the Service principal with the role of Virtual Machine Contributor. It just lets the user manage the VM, but without access to the VM and also do not have the permission to access the Azure portal.
Then you can use this service principal to execute the Azure CLI, Azure PowerShell commands or the REST API to start/stop the Azure VM, it does not cost.
Is there a (simple) way to start/stop virtual machine on Azure without having to access the portal ? By "simple" I mean something that you don't need to run some line code and that can be as easy as opening a RDP file.
There are SDK's available which you can use along with CLI to have programmatic access to the VM - in this manner, you do not require access to the portal.
Alternatively, is there a way not to be billed of running (but idle) virtual machine?
You will be billed for idle VM as this still means that VM is operational. To save costs, terminate the VM and create the VM again when required.
I am trying to enable azure monitor feature for my virtual machines which checks for health and performance of the VM using terraform but I am not able to find the right documentation for the same. Can you help me for the same because I want detailed monitoring for azure.
This is what I want to automate using terraform, enable health & performance using Azure Monitor for VM's
Here is the Azure Monitor for VM Screenshot
https://ibb.co/JmzfNZN
Enable Azure Monitor for VMs service is still in preview mode and is not available as a module in Terraform.
To raise a new feature request in Terraform for Azure, please use the below link:
https://github.com/terraform-providers/terraform-provider-azurerm/issues/new?template=enhancement.md
The VM Role preview in Windows Azure ends on May 31, 2013 and Microsoft urges to migrate VM Roles to "proper" Virtual Machines that are in General Availability as described here:
http://msdn.microsoft.com/library/3dae01d2-2397-47ed-a134-f9ffe58a9b52.aspx
But how do I know which of the Virtual Machines running in Azure are VM Roles and which are Windows Azure Virtual Machines?
I wrote a blog post that may help: Do I have VM Roles that I should migrate? at http://blogs.msdn.com/b/benjguin/archive/2013/04/19/do-i-have-vm-roles-that-i-should-migrate.aspx
You probably see it easily in the portal, but an easy check could be to store something on your disk and stop/delete and recreate the machine. If the file is no longer there, that means it's a VM role.
I also believe you cannot see VMRole in the new portal (and only in the old portal)
I would like to create vhd file for Machine which i have connected from Auzre portal remotely.
I had gone through VM roles in window azure and came to point that first i required to take image of machine and for that requires Hyper-v Manager but it is also available on Window server 2008 R2 , so i have configured os of my deployment to R2 but still there is no option of Hyper-v Manager.
Not sure I completely understand your question, but I think you're asking about managing your VHDs in Windows Azure with Hyper-V running in Windows Azure. Is that correct?
In Windows Azure, there's no Hyper-V Manager that you access. You only use Hyper-V locally, on a local Windows 2008 server, to create your VHDs. These VHDs are then uploaded to Windows Azure.
I suggest you download the Windows Azure Platform Training Kit and run through the Virtual Machine Role lab, as it shows all the necessary steps. You'll see that all Hyper-V access is done on-premise, not in Windows Azure. Once the vhd is created:
Mount a drive containing the Windows Azure extensions, and install those to your vhd.
Run the csupload command line tool (part of the Windows Azure SDK) to upload your vhd to your Windows Azure account.
Create a new Windows Azure project in Visual Studio, adding a VM Role, configuring it to look into your subscription and letting you select the vhd you just uploaded.
Create a new Hosted Service via the portal, then uploading the newly-created Windows Azure deployment package.
There are more details to each of those steps, which are all spelled out in great detail in the VM Role lab mentioned above.