WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud
  • Tanzu
    • Application Modernization
    • Tanzu services
    • Tanzu Community Edition
    • Tanzu Kubernetes Grid
    • vSphere with Tanzu
  • Home Lab
  • Nested Virtualization
  • Apple
You are here: Home / ESXi / Quick Tip - Adding a vTPM (Virtual Trusted Platform Module) to a Nested ESXi VM

Quick Tip - Adding a vTPM (Virtual Trusted Platform Module) to a Nested ESXi VM

05.13.2022 by William Lam // 1 Comment

I had an interesting question this morning asking whether it was possible to add a vTPM (Virtual Trusted Platform Module) to a Nested ESXi VM? The user was interested in testing a particular scenario with the new vSphere Trust Authority feature that was introduced in the vSphere 7.0. I personally had not done much with vTPM and I had assumed it should just work as long as you have a physical TPM chip in the underlying hardware and you have setup either a Standard or Native Key Provider within your vCenter Server.

The user observed that adding a vTPM to a Windows VM was possible using the vSphere UI but when attempting to perform the same operation on a Nested ESXi VM, the option to add vTPM device was not available. After spending ~30 minutes asking around for hardware that had a physical TPM, I remember that my Quartz Canyon NUC (NUC 9 Pro) is a Xeon based system and it has TPM 2.0 chip. I was able to take a closer look and quickly found the solution was very pretty straight forward!

As most folks know, Nested ESXi and Nested Virtualization is not officially supported by VMware, so I suspect that the workflow for adding vTPM simply did not consider Nested ESXi as a valid GuestOS or blocked it by default within the vSphere UI. With that said, you can absolutely add vTPM to a Nested ESXi VM using the vSphere API and luckily, you can easily do this by using PowerCLI's New-VTpm cmdlet.

Here is the command which retrieves the desired Nested ESXi VM by name and then adds the vTPM device:

Get-VM "Nested_ESXi7.0u3c" | New-VTpm


Once the operation has completed, we can now navigate to the vSphere UI and we should now see a vTPM device has been added to our Nested ESXi VM


We can also confirm that the Nested ESXi VM can see vTPM device by running the following ESXCLI command:

esxcli hardware trustedboot get


Lastly, we can add our Nested ESXi to a vSphere Cluster and enable the vSphere Trust Authority state, which also requires the use of PowerCLI and we can now see that vSphere Trust Authority has been properly configured using a Nested ESXi VM and vTPM device!

More from my site

  • Updates to Nested ESXi Virtual Appliance for vSphere 7.0 Update 3
  • Updated Nested ESXi Appliances for 7.0 Update 1d & 2a
  • Exploring the new vSphere with Tanzu VM Service with Nested ESXi
  • Simplified Nested ESXi installation in ESXi 7.0 Update 2 using HTTP Boot over VirtualEFI
  • Disabling TPM 2.0 connection cannot be established message in ESXi for Intel NUC 10
Share this...
  • Twitter
  • Facebook
  • Linkedin
  • Reddit
  • Pinterest

Categories // ESXi, Nested Virtualization, vSphere Tags // Nested ESXi, TPM, vTPM

Comments

  1. Joschua says

    05/17/2022 at 9:56 pm

    That would be a nice feature for a more secure version of the VSAN wittness node.

    Reply

Leave a Reply to Joschua Cancel reply

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

Search

Author

William Lam is a Senior Staff Solution Architect working in the VMware Cloud team within the Cloud Infrastructure Business Group (CIBG) at VMware. He focuses on Cloud Native technologies, Automation, Integration and Operation for the VMware Cloud based Software Defined Datacenters (SDDC)

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

Connect

  • Email
  • GitHub
  • LinkedIn
  • RSS
  • Twitter
  • Vimeo

Support

Recent

  • A first look at the new vSphere+ & vSAN+ Cloud Service 07/01/2022
  • Quick Tip - Prepare VMware Photon OS for use with vSphere Guest OS Customization and cloud-init 06/29/2022
  • Using the new vSphere Guest OS Customization with cloud-init in vSphere 7.0 Update 3 06/27/2022
  • How to forcefully disconnect a vSphere VM Console session? 06/24/2022
  • Quick Tip - Using ESXi Scripted Installation (kickstart) to configure IPv6 networking 06/21/2022

Advertisment

Copyright WilliamLam.com © 2022

 

Loading Comments...