WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple
You are here: Home / Automation / VM Creation Date now available in vSphere 6.7

VM Creation Date now available in vSphere 6.7

04.27.2018 by William Lam // 13 Comments

Last year, I wrote about a new Virtual Machine API property called createDate which provides customers a method of retrieving the original creation date and time of a VM. This vSphere API was first introduced in VMware Cloud on AWS and with the release of vSphere 6.7, it is also now available for on-premises customers to consume.

I know this is a feature that many customers have been asking for (including myself) and I am super happy to finally see this information automatically captured and persisted as part of the VM configuration. Customers no longer have to query the vCenter Server Events API to retrieve this information and store it externally, since it can be rotated out and basically lost due to your vCenter Server Events retention configuration. As of right now, the VM creation date is only available using the vSphere API, it is currently not available in the vSphere H5 Client and hopefully I will be able to convince PM to add this useful piece information into the UI as well!

The createDate property is located under VirtualMachine->Config and can be accessed using any one of the supported vSphere 6.7 Automation SDKs which also includes PowerCLI (you will need to install PowerCLI 10.1.0 which enables support for vSphere 6.7)

Here is an example of retrieving the createDate for a VM named esxi67-01:

(Get-VM -Name esxi67-01).ExtensionData.Config.createDate


Here are a few things to be aware of regarding the createDate behavior:

  • BOTH vCenter Server and ESXi hosts must be upgraded to 6.7 to make use of the new API
  • This API is available on both vCenter Server as well as ESXi hosts running 6.7
  • Only new VMs that were created after upgrading to 6.7 will include this property with the creation date
  • VMs that were created prior to upgrading 6.7 will not have their original creation date, but rather a default value of 1970-01-01T00:00:00Z. If ESXi hosts have not been upgraded but vCenter Server has, then the API property will be unset (null)
  • You can programmatically check whether an ESXi host supports the new createDate property by querying its capabilities using the vSphere API. Here is a PowerCLI example:

    (Get-VMHost -Name 192.168.30.10).ExtensionData.Capability.VmCreateDateSupported

  • VMs created in a vSphere 6.7 environment can be Cross vCenter vMotion to other non-vSphere 6.7 environments and migrated back while retaining its original createDate value. This is done so by storing the value in the extraConfig property of a VM (this is best effort support and we recommend only migrating to vSphere 6.7 or newer environments)

More from my site

  • New Instant Clone Architecture in vSphere 6.7 – Part 2
  • New Instant Clone Architecture in vSphere 6.7 - Part 1
  • New vSphere 6.7 APIs worth checking out
  • Leveraging Instant Clone in vSphere 6.7 for extremely fast Nested ESXi provisioning
  • Native MAC Learning in vSphere 6.7 removes the need for Promiscuous mode for Nested ESXi

Categories // Automation, vSphere 6.7 Tags // create date, createDate, ESXi 6.7, vSphere 6.7, vSphere API

Comments

  1. *protectedrdronov says

    04/29/2018 at 10:57 pm

    This is awesome news William! Definitely one of those things we can benefit from.

    Reply
  2. *protectedPierre says

    04/30/2018 at 1:43 am

    it ismind boggling that we had to wait 15 years for such a basic yet important information to be available....

    Reply
    • *protectedWaWa Choy says

      05/09/2018 at 5:57 am

      We use an annotation which we populate when the VM is created. What i would like to know is if this property can be edited so i can drop the annotation and fully populate this field.

      Reply
      • William Lam says

        05/09/2018 at 5:59 am

        No, the value of this property is automatically generated by the platform and can not be modified.

        Reply
  3. *protectedDag Kvello says

    04/30/2018 at 2:31 am

    Now all we need is:
    (Get-VM -Name vmname).ExtensionData.Config.createdBy

    It would make life so much easier when creating personalized notofications on snaptshots etc.

    Reply
    • *protectedDave says

      05/02/2018 at 8:03 am

      Came to ask, if a createdBy field was an option. Looks like I need to keep waiting.

      Reply
    • *protectedBrett Monroe says

      05/23/2018 at 1:28 pm

      +1
      Also would love a createdBy attribute for a snapshot object

      Reply
      • *protectedPedro ET Ferreira says

        12/12/2018 at 10:18 am

        These are great news!! But I would also love to have a createdBy attribute!

        Reply
  4. *protectedMichael Gonzalez says

    12/06/2019 at 9:19 am

    Thanks for that, just what I was looking for and works nicely!

    Reply
  5. *protectedJason says

    04/16/2020 at 1:41 pm

    too bad it also takes into account the creation of snapshots. we use avamar image backups and so snapshots are taken every night making this unsable for me.

    Reply
  6. *protectedmichael says

    08/03/2020 at 5:27 am

    which module should we use to retrieve the create date information i googled through for python and i dont get any leads

    Reply
  7. *protecteddésiré-lévi says

    11/19/2021 at 10:21 am

    Is there a way to obtain this information using the Java vSphere Automation SDK ?

    Reply
  8. *protectedBill Weng says

    02/23/2024 at 10:12 am

    I am trying to extend our existing property_filter_spec in propertyCollector call to add config.createDate, in my perl sdk 7.0 application. My vCenter is on vSphere 7.0 and the VM was newly created. What could be the reason this data is not in the response but all other properties are? Appreciated if you can point me some directions on how to debug this issue. Thx.

    Reply

Thanks for the comment!Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • VMware Flings is now available in Free Downloads of Broadcom Support Portal (BSP) 05/19/2025
  • VMUG Connect 2025 - Minimal VMware Cloud Foundation (VCF) 5.x in a Box  05/15/2025
  • Programmatically accessing the Broadcom Compatibility Guide (BCG) 05/06/2025
  • Quick Tip - Validating Broadcom Download Token  05/01/2025
  • Supported chipsets for the USB Network Native Driver for ESXi Fling 04/23/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025

 

Loading Comments...