Monitor virtual machines with Azure Monitor: Deploy agent - Azure Monitor (2024)

  • Article

This article is part of the guide Monitor virtual machines and their workloads in Azure Monitor. It describes how to deploy the Azure Monitor agent to your Azure and hybrid virtual machines in Azure Monitor.

Note

This scenario describes how to implement complete monitoring of your Azure and hybrid virtual machine environment. To get started monitoring your first Azure virtual machine, see Monitor Azure virtual machines.

Any monitoring tool like Azure Monitor, requires an agent installed on a machine to collect data from its guest operating system. Azure Monitor uses the Azure Monitor agent, which supports virtual machines in Azure, other cloud environments, and on-premises.

Prerequisites

Create a Log Analytics workspace

You don't need a Log Analytics workspace to deploy the Azure Monitor agent, but you will need one to collect the data that it sends. There's no cost for the workspace, but you do incur ingestion and retention costs when you collect data.

Many environments use a single workspace for all their virtual machines and other Azure resources they monitor. You can even share a workspace used by Microsoft Defender for Cloud and Microsoft Sentinel, although many customers choose to segregate their availability and performance telemetry from security data. If you're getting started with Azure Monitor, start with a single workspace and consider creating more workspaces as your requirements evolve. VM insights will create a default workspace which you can use to get started quickly.

For complete details on logic that you should consider for designing a workspace configuration, see Design a Log Analytics workspace configuration.

Workspace permissions

The access mode of the workspace defines which users can access different sets of data. For details on how to define your access mode and configure permissions, see Manage access to log data and workspaces in Azure Monitor. If you're just getting started with Azure Monitor, consider accepting the defaults when you create your workspace and configure its permissions later.

Tip

Multihoming refers to a virtual machine that connects to multiple workspaces. There's typically little reason to multihome agents for Azure Monitor alone. Having an agent send data to multiple workspaces most likely creates duplicate data in each workspace, which increases your overall cost. You can combine data from multiple workspaces by using cross-workspace queries and workbooks. One reason you might consider multihoming is if you have an environment with Microsoft Defender for Cloud or Microsoft Sentinel stored in a workspace that's separate from Azure Monitor. A machine being monitored by each service needs to send data to each workspace.

Prepare hybrid machines

A hybrid machine is any machine not running in Azure. It's a virtual machine running in another cloud or hosted provider or a virtual or physical machine running on-premises in your datacenter. Use Azure Arc-enabled servers on hybrid machines so you can manage them similarly to your Azure virtual machines. You can use VM insights in Azure Monitor to use the same process to enable monitoring for Azure Arc-enabled servers as you do for Azure virtual machines. For a complete guide on preparing your hybrid machines for Azure, see Plan and deploy Azure Arc-enabled servers. This task includes enabling individual machines and using Azure Policy to enable your entire hybrid environment at scale.

There's no additional cost for Azure Arc-enabled servers, but there might be some cost for different options that you enable. For details, see Azure Arc pricing. There is a cost for the data collected in the workspace after your hybrid machines are onboarded, but this is the same as for an Azure virtual machine.

Network requirements

The Azure Monitor agent for both Linux and Windows communicates outbound to the Azure Monitor service over TCP port 443. The Dependency agent uses the Azure Monitor agent for all communication, so it doesn't require any another ports. For details on how to configure your firewall and proxy, see Network requirements.

There are three different options for connect your hybrid virtual machines to Azure Monitor:

  • Public internet. If your hybrid servers are allowed to communicate with the public internet, then they can connect to a global Azure Monitor endpoint. This is the simplest configuration but also the least secure.

  • Log Analytics gateway. With the Log Analytics gateway, you can channel communications from your on-premises machines through a single gateway. Azure Arc doesn't use the gateway, but its Connected Machine agent is required to install Azure Monitor agent. For details on how to configure and use the Log Analytics gateway, see Log Analytics gateway.

  • Azure Private Link. By using Azure Private Link, you can create a private endpoint for your Log Analytics workspace. After it's configured, any connections to the workspace must be made through this private endpoint. Private Link works by using DNS overrides, so there's no configuration requirement on individual agents. For details on Private Link, see Use Azure Private Link to securely connect networks to Azure Monitor. For specific guidance on configuring private link for your virtual machines, see Enable network isolation for the Azure Monitor agent.

Agent deployment options

The Azure Monitor agent is implemented as a virtual machine extension, so you can install it using a variety of standard methods including PowerShell, CLI, and Resource Manager templates. See Manage Azure Monitor Agent for details on each. Other notable methods for installation are described below.

MethodScenariosDetails
Azure PolicyProduction deployment at scaleIf you have a significant number of virtual machines, you should deploy the agent using Azure Policy as described in Manage Azure Monitor Agent or Enable VM insights by using Azure Policy. This will ensure that the agent is automatically added to existing virtual machines and any new ones that you deploy.
Data collection rule in Azure portalTesting and simple deploymentsWhen you create a data collection rule in the Azure portal as described in Collect events and performance counters from virtual machines with Azure Monitor Agent, you have the option of specifying virtual machines to receive it. The Azure Monitor agent will be automatically installed on any machines that don't already have it.
VM insights in Azure portalTesting and simple deployments with preconfigured monitoringVM insights provides simplified onboarding of agents in the Azure portal. With a single click for a particular machine, it installs the Azure Monitor agent, connects to a workspace, and starts collecting performance data. You can optionally have it install the dependency agent and collect processes and dependency data to enable the map feature of VM insights.
Windows client installerClient machinesUse the Windows client installer to install the agent on Windows clients such as Windows 11. For different options deploying the agent on a single machine or as part of a script, see Manage Azure Monitor Agent.

Legacy agents

The Azure Monitor agent replaces legacy agents that are still available but should only be used if you require particular functionality not yet available with Azure Monitor agent. Most users will be able to use Azure Monitor without the legacy agents.

The legacy agents include the following:

  • Log Analytics agent: Supports virtual machines in Azure, other cloud environments, and on-premises. Sends data to Azure Monitor Logs. This agent is the same agent used for System Center Operations Manager.
  • Azure Diagnostic extension: Supports Azure Monitor virtual machines only. Sends data to Azure Monitor Metrics, Azure Event Hubs, and Azure Storage.

See Supported services and features for the current features supported by Azure Monitor agent. See Migrate to Azure Monitor Agent from Log Analytics agent for details on migrating to the Azure Monitor agent if you already have the Log Analytics agent deployed.

Next steps

  • Configure data collection for machines with the Azure Monitor agent.
Monitor virtual machines with Azure Monitor: Deploy agent - Azure Monitor (2024)

FAQs

How do I monitor a process on Azure VM? ›

If you enable VM insights, the Azure Monitor agent is installed and starts sending a predefined set of performance data to Azure Monitor Logs. You can create other data collection rules to collect events and other performance data.

On which virtual machines is the Microsoft monitoring agent installed? ›

You can install Azure Monitor Agent on Azure virtual machines and on Azure Arc-enabled servers by using the Azure CLI command for adding a virtual machine extension.

How to Monitor a virtual machine? ›

VM monitoring tools function by tracking certain critical metrics indicative of the performance and health of your virtual devices to ensure they're running efficiently. Much of this tracking is performed by software automatically collecting and analyzing the many event logs produced by virtual machines.

How to view Virtual Machines in Azure? ›

Go to the Azure portal to connect to a VM. Search for and select Virtual machines. Select the virtual machine from the list. At the beginning of the virtual machine page, select Connect.

What is an example of a virtual machine monitor? ›

The VMM kernel runs alongside the host OS, and calls for I/O are redirected to virtual drivers that call the native API of the host OS. Examples of OS-hosted VMMs are VMware Workstation, VMware Server, Parallels Workstation and Parallels Desktop for Mac.

How do I monitor Azure Virtual Desktop? ›

From the Azure Virtual Desktop overview page, select Host pools, then select the pooled host pool you want to monitor. From the host pool overview page, select Insights, then select Open Configuration Workbook. Select the Session host data settings tab in the configuration workbook.

What is an Azure monitor agent? ›

Azure Monitor Agent is General Availablity (GA) for data collection and is used for data collection by various Azure Monitor features and other Azure services. For details, see Supported services and features. Consider installing Azure Monitor Agent together with a legacy agent for a transition period.

Which two data types should you use Azure monitor? ›

Explanation: Azure Monitor provides two primary data types for monitoring and analysis: Metrics and Logs. Metrics provide a numerical view of performance data, while Logs provide a detailed record of events and activities.

What port does the Azure Monitor Agent use? ›

The Azure Monitor agent for both Linux and Windows communicates outbound to the Azure Monitor service over TCP port 443. The Dependency agent uses the Azure Monitor agent for all communication, so it doesn't require any another ports. For details on how to configure your firewall and proxy, see Network requirements.

How to get VM utilization report in Azure? ›

You can do this by going to the Azure portal, selecting "Monitor" from the left-hand menu, selecting "Metrics" under "Monitoring data", and selecting the appropriate subscription and VM resource type.

How to check Azure VM activity log? ›

View resource group or subscription-level activity log insights. To view activity log insights at the resource group or subscription level: In the Azure portal, select Monitor > Workbooks. In the Insights section, select Activity Logs Insights.

How to check VM usage? ›

You can analyze your virtual machine's CPU and memory utilization by using the Host Resource Analytics application to view and compare detailed CPU and memory information across one of more virtual machines. From this application, you can: View usage analytics grouped by date and time.

Top Articles
Salario para Business Broker en Estados Unidos - Salario Medio
1.5 Monopolistic Competition, Oligopoly, and Monopoly – Exploring Business
English Bulldog Puppies For Sale Under 1000 In Florida
Katie Pavlich Bikini Photos
Gamevault Agent
Pieology Nutrition Calculator Mobile
Hocus Pocus Showtimes Near Harkins Theatres Yuma Palms 14
Hendersonville (Tennessee) – Travel guide at Wikivoyage
Compare the Samsung Galaxy S24 - 256GB - Cobalt Violet vs Apple iPhone 16 Pro - 128GB - Desert Titanium | AT&T
Vardis Olive Garden (Georgioupolis, Kreta) ✈️ inkl. Flug buchen
Craigslist Dog Kennels For Sale
Things To Do In Atlanta Tomorrow Night
Non Sequitur
Crossword Nexus Solver
How To Cut Eelgrass Grounded
Pac Man Deviantart
Alexander Funeral Home Gallatin Obituaries
Shasta County Most Wanted 2022
Energy Healing Conference Utah
Geometry Review Quiz 5 Answer Key
Hobby Stores Near Me Now
Icivics The Electoral Process Answer Key
Allybearloves
Bible Gateway passage: Revelation 3 - New Living Translation
Yisd Home Access Center
Home
Shadbase Get Out Of Jail
Gina Wilson Angle Addition Postulate
Celina Powell Lil Meech Video: A Controversial Encounter Shakes Social Media - Video Reddit Trend
Walmart Pharmacy Near Me Open
Marquette Gas Prices
A Christmas Horse - Alison Senxation
Ou Football Brainiacs
Access a Shared Resource | Computing for Arts + Sciences
Vera Bradley Factory Outlet Sunbury Products
Pixel Combat Unblocked
Movies - EPIC Theatres
Cvs Sport Physicals
Mercedes W204 Belt Diagram
Mia Malkova Bio, Net Worth, Age & More - Magzica
'Conan Exiles' 3.0 Guide: How To Unlock Spells And Sorcery
Teenbeautyfitness
Where Can I Cash A Huntington National Bank Check
Topos De Bolos Engraçados
Sand Castle Parents Guide
Gregory (Five Nights at Freddy's)
Grand Valley State University Library Hours
Holzer Athena Portal
Hello – Cornerstone Chapel
Stoughton Commuter Rail Schedule
Selly Medaline
Latest Posts
Article information

Author: Kelle Weber

Last Updated:

Views: 5671

Rating: 4.2 / 5 (73 voted)

Reviews: 80% of readers found this page helpful

Author information

Name: Kelle Weber

Birthday: 2000-08-05

Address: 6796 Juan Square, Markfort, MN 58988

Phone: +8215934114615

Job: Hospitality Director

Hobby: tabletop games, Foreign language learning, Leather crafting, Horseback riding, Swimming, Knapping, Handball

Introduction: My name is Kelle Weber, I am a magnificent, enchanting, fair, joyous, light, determined, joyous person who loves writing and wants to share my knowledge and understanding with you.