Azure Update Management
Step by step procedure to install updates on Azure Windows/Linux servers with Azure Update Management:
Azure Update management is an Automation tool /service used to install patches on Azure on-premises Windows/Linux computers. Below are the four steps to be followed to install the missing patches on computers using Azure update management component.
Create a Log Analytics workspace.
Create an Automation account.
Link the Automation account with the Log Analytics workspace.
Enable Update Management for Azure VMs.
Create a Log Analytics workspace:
In the Azure portal, select create a resource> Log Analytics workspaces>create
Fill up the details such as Resource group,Name,Region in basics tab> Review and create with default settings
Create an Automation account:
In the Azure portal, select create a resource>Automation accounts>create
Fill up the details such as Resource group,Name,Region in basics tab> Review and create with default settings
Link the Automation account with the Log Analytics workspace:
Go to Automation Account pane>Update Management>Select existing Log Analytics workspace>Enable
Click on Add Azure VM’s>Select the VM and enable update management for Azure VM’s
It will take approx. 15 mins to reflect your virtual machine in Update management pane
Deploy the Log Analytics agent and connect to a Log Analytics workspace. Before you deploy agent copy the Workspace and primary key from Log analytics >Agents Management
Install Log analytics agent on windows:
Download the Agent file from Microsoft and install on On-premises computer
I Agree>Next>Connect the agent to Azure log Analytics (OMS)
>Next>Azure Commercial> Fill up the Workspace ID and Key you copied from Agent Management
>Next >Install
Install OMS Agent on Linux Server
You can use the below command to install OMS agent on linux server. Update your Workspace id and Primary key in the below command and run as root /sudo
wget https://raw.githubusercontent.com/Microsoft/OMS-Agent-for-Linux/master/installer/scripts/onboard_agent.sh && sh onboard_agent.sh -w <YOUR WORKSPACE ID> -s <YOUR WORKSPACE PRIMARY KEY>
Example : sudo wget https://raw.githubusercontent.com/Microsoft/OMS-Agent-for-Linux/master/installer/scripts/onboard_agent.sh && sh onboard_agent.sh -w d442485a-6cb6-47e5-be9d-39f6584d8198 -s LTfuzoXtrDxamiCl7CeNbeDgK8XDE+p4s6WgRClvlaxpd2OomayUJZXI9au44Tc5qfTzezGWTvjL5qh+rQxs/w==
Schedule and update Deployment:
Go to Automation account>Update management >Schedule update deployment
Under New update deployment>Provide name>Operating System
Select Groups to update > Fill Up subscription, resource groups, locations of Azure VMs for your deployment >add >ok
Select Machines> Select the VM’s you want to deploy patches
Select the update classification as mentioned below based on the requirement.
Select Include/exclude selecting specific updates for deployment
Select Schedule setting to configure the schedule for deployment of patches>ok
Once the deployment is completed, Go to Update Management >History > to View the results of completed update deployment
Now you successfully deployed the missing patches using Azure update manager.
Use Dynamic groups with Update Management:
If you have more than 1000 machines, Microsoft recommend that you split up the updates among multiple update schedules.
Dynamic Groups can be created based on
Subscription
Resource groups
Locations
Tags
Creating Dynamic Group for Patch Deployment:
Go to Azure monitor>Logs>
Example : Heartbeat | where Computer contains "Red" | distinct Computer
>Run > Save as function
Provide the group name >Save
Now you should be able to view the dynamic group while scheduling the Windows update deployment.
Thank you!!!
Comments
Post a Comment