Azure Linux VM OS version details in CSV file

BHATT, KANHA 1 Reputation point
2021-10-01T03:57:52.56+00:00

Hi All,

I want to provide a list of Azure Linux VM OS version details in a document. Manually it will take much time. Is there any other way?

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,085 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. prmanhas-MSFT 17,886 Reputation points Microsoft Employee
    2021-10-01T08:38:37.88+00:00

    @BHATT, KANHA Thank you for your email!!!

    You can try to run below on Azure CLI which will give information about OS version and other details as well. This will give information about all the VM irrespective of OS in your subscription

    az vm list --query '[].{ offer:storageProfile.imageReference.offer,publisher:storageProfile.imageReference.publisher, sku:storageProfile.imageReference.sku,version:storageProfile.imageReference.version}' -o json | ConvertFrom-Json | export-csv -Path E:\test.csv -NoTypeInformation

    Output will look something like below in csv file:

    136869-image.png

    Hope it helps!!!

    Please "Accept as Answer" if it helped so it can help others in community looking for help on similar topics.

    0 comments No comments