- Lab
-
Libraries: If you want this lab, consider one of these libraries.
- Cloud

Use PowerShell to Resize an Azure Virtual Machine in an Availability Set
Your company's finance department explains that the cost of Azure virtual machines (VMs) is over budget. You must find an easy solution to decrease the cost of Azure VMs in your subscription. Using only PowerShell, how do you identify the VMs with low CPU utilization and change their size?

Lab Info
Table of Contents
-
Challenge
Start Cloud Shell
- Click the Cloud Shell icon (
>_
) in the upper right. - Click PowerShell.
- Select No storage account required.
- Select the lab provided subscription.
- Click Apply.
- Click the Cloud Shell icon (
-
Challenge
Get the VM Size and CPU Metrics
-
Find the current size of the VMs.
-
Get the VM subscription name.
-
Check VM CPU metrics.
-
-
Challenge
Resize VMs in Availability Set
-
Check which VMs are available to resize within the VM hardware cluster.
-
Perform the PowerShell commands to resize the VM(s).
-
About the author
Real skill practice before real-world application
Hands-on Labs are real environments created by industry experts to help you learn. These environments help you gain knowledge and experience, practice without compromising your system, test without risk, destroy without fear, and let you learn from your mistakes. Hands-on Labs: practice your skills before delivering in the real world.
Learn by doing
Engage hands-on with the tools and technologies you’re learning. You pick the skill, we provide the credentials and environment.
Follow your guide
All labs have detailed instructions and objectives, guiding you through the learning process and ensuring you understand every step.
Turn time into mastery
On average, you retain 75% more of your learning if you take time to practice. Hands-on labs set you up for success to make those skills stick.