WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple
You are here: Home / Automation / vSphere Tag Attach/Detach events now in VMware Cloud on AWS

vSphere Tag Attach/Detach events now in VMware Cloud on AWS

03.05.2019 by William Lam // 4 Comments

The underlying products (vSphere, vSAN & NSX) that run within VMware Cloud on AWS (VMC) are constantly being improved with new capabilities and enhancements. As a service, VMC is updated more frequently than a traditional on-premise environment and one huge benefit for our customers is that they get to access all the latest and greatest features of the platform!

Yesterday, I came to learn about some improvements that we had made to our vSphere Tagging infrastructure to start publishing vCenter Server Events for when a vSphere Tag is attached or detached from an inventory object such as a Virtual Machine. This has been a frequently requested feature by our customers, especially for auditing purposes and this also enables the ability to perform additional actions through the use of a vCenter Alarm.

UPDATE (10/13/20) - vSphere 7.0 Update 1 now includes vCenter Events for both vSphere Tag Attach/Detach operations. For complete list of out of the box vCenter Server Events, you can refer to this Github repo.

In the vSphere UI for a VMC vCenter Server, you can now see these new tagging events by selecting the vCenter Server inventory object and then go to Monitor->Events and filter by "attached tag" or "detached tag".



The two new tag events are defined by the following new event types in vCenter Server:

  • com.vmware.cis.tagging.attach
  • com.vmware.cis.tagging.detach

This also means that you can programmatically retrieve these events using the vSphere API or any of the supported vSphere SDKs including PowerCLI.

Here are some examples using PowerCLI and the Get-VIEvent and filtering by the two new event type:

Get-VIEvent | where {$_.EventTypeId -match "com.vmware.cis.tagging.attach"}

Get-VIEvent | where {$_.EventTypeId -match "com.vmware.cis.tagging.detach"}


One thing that I did notice is that we currently do not publish events for basic CRUD (Create, Update & Delete) operations for vSphere Tags as well as Tag Categories, I know this is probably something customers would also like to see in addition to attaching and detaching a tag. Hopefully this is something that can also be improved in a future update and let us know if this is something you would be interested in or if there are other scenarios related to tags that should be captured as part of our vCenter Event stream.

More from my site

  • Using PowerCLI and vSphere Tags to create/migrate HCX Mobility Groups to VMware Cloud SDDC
  • Integrating VMware Cloud Notification Gateway with VMware Event Broker Appliance (VEBA)
  • Custom notification and automation based on host failure in VMware Cloud on AWS
  • New vCenter events for vSphere 7, VMware Cloud on AWS 1.10 and vSphere with Kubernetes
  • Forwarding vCenter Events into AWS EventBridge using vCenter Event Broker Appliance

Categories // Automation, VMware Cloud on AWS, vSphere Tags // event, tag, VMC, VMware Cloud on AWS

Comments

  1. *protectedرزرو هتل says

    03/06/2019 at 12:35 pm

    this article is amazing
    thank you so much
    it is very useful

    Reply
  2. *protectedvirt.ninja says

    03/12/2019 at 7:48 am

    Any idea of how soon this will make it into on-premise vSphere? We need this!

    Reply
    • *protectedvirt.ninja says

      09/18/2019 at 6:15 am

      6 months on, any word of this making it into an on premise vCenter release?

      Reply
  3. *protectedBrian Phipps says

    05/16/2020 at 1:17 am

    The problem that I've just determined, is that these events are associated with the friendly name of the object on which they are triggered and not the MOID. There is therefore no means to correlate these back to the originating object, when for example you have two virtual machines with the same name.

    Reply

Leave a Reply to Brian PhippsCancel 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

  • 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
  • vCenter Identity Federation with Authelia 04/16/2025
  • vCenter Server Identity Federation with Kanidm 04/10/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...