PowerShell script to get an CPU/MEM/DISK of azure windows VM's which are above 85%. And the result am trying to get in mail on HTML format. Anyone have script?

Nandhini A 20 Reputation points
2024-08-30T15:39:49.36+00:00

Am trying to fetch the CPU, memory and disk usage of 100+ of azure windows servers using PowerShell script. And the report to be mailed in html table format.

attached below sample format, which am trying to make ,with cpu//mem//disk columns. sample pic

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,790 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,922 questions
PowerShell
PowerShell
A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
2,458 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Akshay kumar Mandha 385 Reputation points Microsoft Vendor
    2024-09-03T17:46:57.9533333+00:00

    Hi Nandhini A,
    Thank you replied back to us after reviewing your question

    Based up on your script could you please go through this document once Windows Server health check script here that could assist in performing a comprehensive health check on your system. This script is designed for system health, including logs, performance metrics, and recent events. you have to customize the script implement add the input parameters accordingly

    If an answer has been helpful, please consider accepting the answer to help increase visibility of this question for other members of the Microsoft Q&A community.
    User's image


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.