I’ve recently had to audit and document several vSphere environments. Multiple hosts had been configured manually and there were some mistakes in the IP settings. I put together this POWERCLI function to report back on these settings and will now use it for documentation moving forward. Hopefully of some use to others too. Connect to a host or vCenter and give it a go.
I don’t know many people that enjoy writing documentation but it is a nessesary evil and can give you the opportunity to be creative with how you produce it. Often I will need to document a point in time install for ESXi hosts so have put together the below PowerCLI function to obtain some hardware and build information back. Running Get-HostDetails after connecting to a host or vCenter There are loads of good examples available but this works well for me. Output as below
Who doesn’t love a bit of automation these days, I certainly like to use code snippets and shortcuts whenever I can. Recently I’ve been deploying some VMs in my homelab and thought I would share some of the POWERCLI I use. I have a Windows 2016 template stored in vCenter that I have recently patched and tweaked to my satisfaction and deploy that with a temporary customization spec to deploy and do the initial config (IP settings and domain join). The key commands to use here to get the IP settings are Get-OScustomizationNicMapping Set-OSCustomizationNicMapping Only started playing with these recently...