I am having 5 subscriptions up on which I am having 50 Virtual machines running across 5 subscriptions. So I need to capture the logs of performance of all the 50 Virtual machines at a time in csv format?

Chatla Ravi 0 Reputation points
2023-07-01T01:18:18.2233333+00:00

I am having 5 subscriptions up on which I am having 50 Virtual machines running across 5 subscriptions. So I need to capture the logs of performance of all the 50 Virtual machines at a time in csv format?

Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,882 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Limitless Technology 44,566 Reputation points
    2023-07-03T11:03:49.84+00:00

    Hello Chatla,

    Thank you for your question and for reaching out with your question today.

    To capture the performance logs of multiple virtual machines across different subscriptions, you can use Azure Monitor. Azure Monitor allows you to collect and analyze performance data from various Azure resources, including virtual machines. Here's a high-level approach to capturing performance logs for your virtual machines:

    1. Enable Azure Monitor for each subscription: Ensure that Azure Monitor is enabled for all five of your subscriptions. This will allow you to collect and store performance data for your virtual machines.
    2. Configure diagnostic settings: In Azure Monitor, configure diagnostic settings for each virtual machine to specify the performance counters you want to monitor and the destination where you want to store the logs. You can choose to store the logs in Azure Storage, Log Analytics workspace, or Event Hubs.
    3. Create Log Analytics workspace: If you don't have a Log Analytics workspace already, create one in Azure. This workspace will serve as the central location for storing and analyzing your performance logs.
    4. Query and export logs: Once the logs are being collected, you can use the Log Analytics Query Language (KQL) to query and analyze the performance data. To export the logs in CSV format, you can use the Log Analytics portal or use the Log Analytics API to programmatically retrieve the data and save it as CSV.
    5. Automation and scripting: If you want to automate the process of capturing logs for all your virtual machines, you can use Azure PowerShell, Azure CLI, or Azure Resource Manager templates to script the configuration of diagnostic settings and export the logs.

    By following these steps, you can effectively capture and export the performance logs of your virtual machines across multiple subscriptions. Remember to review and fine-tune the performance counters you want to monitor based on your specific requirements.

    I used AI provided by ChatGPT to formulate part of this response. I have verified that the information is accurate before sharing it with you.

    If the reply was helpful, please don’t forget to upvote or accept as answer.

    Best regards.

    0 comments No comments

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.