VM creation date

Category: azure scripting and command line tools

Question

Fantaka on Mon, 28 Jan 2019 08:14:02


Hello,

Can anyone help on how to get all azure Vm's creation time ?

i know there is a way to get this information from the activity log , baut this is not enough when we need to get the age of a VM older than 3 month .


 

Replies

BhargaviAnnadevara-MSFT on Mon, 28 Jan 2019 21:14:00


Hello Fantaka,

There is no command in Powershell as of now to get the VM creation date directly. However, considering that your disk and VMs were created at the same time, you could use the following Azure Powershell Command to retrieve the creation time of the disk associated with your Virtual machine:

Get-AzureVM -ServiceName myubuntu | Get-AzureOSDisk | select MediaLink

Also, check this blog out for exploring other alternatives for the same.

Hope this helps!



BhargaviAnnadevara-MSFT on Fri, 08 Feb 2019 09:10:23


Hello Fantaka,

Have you had a chance to check if any of the above options worked for you? Please let us know otherwise and we'll be happy to assist you!

BhargaviAnnadevara-MSFT on Sun, 31 Mar 2019 06:00:32


Hello Fantaka,

Have you had a chance to check if the above option worked for you? Please let us know otherwise and we'll be happy to assist you!