WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple

PowerCLI 13.0 on Photon OS

12.08.2022 by William Lam // 3 Comments

I received a question from Andrea Peetz, asking whether the new Image Builder cmdlets, which is part of the new PowerCLI 13.0 release would work with Photon OS 3.0 (PH3)? After speaking with the PowerCLI team, it looks like Photon OS 3.0 is not compatible with the new cmdlets. If you attempt to use one of the Image Builder cmdlets like Get-EsxSoftwareDepot, you will get the following error:

Unable to cast object of type 'System.IO.FileStream' to type 'System.IO.Pipes.PipeStream'.


With that said, if you do not require the Image Builder cmdlets, then the rest of the PowerCLI cmdlets should work just fine.

While I have not used PH3 for quite some time now, I do use Photon OS 4.0 (PH4) on a regular basis. I was curious if I would have better luck with the new Image Builder cmdlets. Unlike PH3 which ships with Python 3.7, which is the required version for the Image Builder cmdlets, PH4 ships with a newer version of Python which is 3.10 and will not work with PowerCLI. We can still meet this requirement, but we will need to install Python via pyenv.

After a quick test, I was able to get the basic Image Builder cmdlets working and while going through a complete end-to-end workflow to make sure everything was working, I ran into a slightly different issue. When using the Export-EsxImageProfile cmdlet to export an ESXi Image Profile to an ISO file, I got the following error:

Can not instantiate 'certified' policy: VibSign module missing.

Quickly debugging the issue with the PowerCLI team, it looks like the VibSign module that has been compiled has a dependency on OpenSSL 1.1 and PH4 ships with OpenSSL 3.0 by default. Luckily, I was able to find a workaround by building the required file from the latest stable OpenSSL 1.1 release. Once the dependency was fulfilled, I was able successfully complete the Image Builder workflow!


Similiar to PH3, if you do not require the use of the Image Builder cmdlets, PowerCLI 13.0 can be installed on PH4 using the instructions below. If you do need to use the Image Builder cmdlets on PH4, you will need to run Step 2 below as that is a required step. I have also reported both of these issues with the PowerCLI team.

[Read more...]

Categories // Automation, PowerCLI Tags // auto deploy, image builder, PowerCLI

Heads Up - Unable to open VIB archive in streaming mode using Export-EsxImageProfile with PowerCLI 13.0

11.30.2022 by William Lam // 10 Comments

An issue that I ran into after upgrading to the latest PowerCLI 13.0 release after it GA'ed was attempting to export an ESXi image profile that I had created to an ISO file using the Export-EsxImageProfile cmdlet and immediately hit the following error:

Export-EsxImageProfile: Error retrieving file for VIB 'VMware_bootbank_esx-update_8.0.0-1.0.20513097': ('vib20/esx-update/VMware_bootbank_esx-update_8.0.0-1.0.20513097.vib', "Unable to open VIB archive in streaming mode: '_SharedFile' object has no attribute 'writing'").

I am an avid use of this cmdlet and have never ran into this issue before and I was not sure if this could be related to the porting of the Image Builder and Auto Deploy cmdlets to PowerShell Core, which was new with the PowerCLI 13.0 release. I have already filed an internal bug and the PowerCLI Engineering team have not had a chance to look at it, but over the past week, I have noticed a number of reports on my blog, VMTN community forums, Reddit and Twitter that other users were also hitting this issue.

As I have already responded in a few of these channels already, a bug has been filed and there is currently not a work around that I am aware of. As I have any updates, I will update this article with more details.

UPDATE - Several readers have informed me that if you update to Python 3.7.9 or greater, the issue should go away.

The options right now is to either use the vSphere Image Builder UI OR vSphere Lifecycle Manager (vLCM) UI or the new vLCM PowerCLI cmdlets, both of which requiring a vCenter Server running vSphere 8.0.

Categories // Automation, ESXi, PowerCLI, vSphere 8.0 Tags // image builder, PowerCLI, vSphere 8.0

Quick Tip - Changes to building custom ESXi images in vSphere 8

11.03.2022 by William Lam // 2 Comments

Historically, when a new version of ESXi is released, customers will use vSphere Image Builder either through the vSphere Image Builder UI or PowerCLI Image Builder cmdlets to create a custom ESXi image to include additional drivers such as the USB Network Native Driver for ESXi Fling.

Note: The current version of the USB Network Native Driver for ESXi Fling is not compatible with ESXi 8.0 and a new version of the driver will be needed. There is currently no ETA on when a new version will be available.

Typically, customers will use their existing vCenter Server deployment, which is usually running an older version to create their new custom ESXi image. This means you are importing a newer ESXi release into your vCenter Server or in the case of the PowerCLI Image Builder cmdlets, you are using an older release of PowerCLI. While this may have worked with previous releases, the assumption that vSphere Image Builder is "forward" compatible with future releases of ESXi is actually an incorrect assumption that many have made, including myself.

I bring this up because in vSphere 8, there have been changes in ESXi where this incompatibility will be observed when attempting to create a custom ESXi 8.0 image using a non-compatible vCenter Server or a PowerCLI release.

[Read more...]

Categories // Automation, ESXi, vSphere 7.0, vSphere 8.0 Tags // ESXi 8.0, image builder, vSphere 8.0

  • 1
  • 2
  • 3
  • Next Page »

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...