WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Hardware Options
    • Hardware Reviews
    • Lab Deployment Scripts
    • Nested Virtualization
    • Homelab Podcasts
  • VMware Nostalgia
  • Apple
You are here: Home / Uncategorized / ESXi Migration Worksheet Script

ESXi Migration Worksheet Script

05.26.2011 by William Lam // 7 Comments

Over the weekend Duncan Epping released a new whitepaper called VMware ESXi 4.1 Operations Guide which documents some of the operational tasks for managing/configuring an ESXi environment. Not only is this a really cool document, but I also found that I was referenced in the whitepaper. This was really neat as it is probably my first reference ever in a whitepaper 🙂

While looking through the other links, I noticed there was another whitepaper written by Duncan's colleague, Kyle and it referenced a host configuration worksheet. When I opened up the document, it was basically a plain PDF form requiring users to manually input some of the important configurations of an ESX host prior to upgrading to ESXi. I thought this would be fine if you only had a few hosts to upgrade, but what if you had several dozens or hundreds of hosts? Manually editing the non-editable PDF document meant you had to use a PDF tool or worse printing it out and writing in the information by hand.

I thought, why not automate it? I decided create a very simple vSphere SDK for Perl script called generateHostConfigurationWorksheet.pl that would allow a user to connect to either a standalone ESX host or to a vCenter server. The script also allows you to specify a list of ESX hosts to extract the information when connecting to vCenter, else by default it will collect information for all your ESX hosts. You also have the option of selecting either an html or csv output.

To run this script, you will need a system that has the vCLI installed or you can use VMware vMA. You will also need to download the script from here. Make sure you set the script to be executable

The script accepts two paraemters:
--output [html|csv] (required)

--hostlist [file-containing-esx-hosts] (optional)

Here is an example of connecting directly to an ESX host:

[vi-admin@tancredi ~]$ ./generateHostConfigurationWorksheet.pl --server vesx41-1.primp-industries.com --username root --output html
Enter password:
Processing vesx41-1.primp-industries.com
Generating vesx41-1.primp-industries.com.html ...

Here is an example of connecting to vCenter and specifying a list of ESX hosts to collect information on:

[vi-admin@tancredi ~]$ ./generateHostConfigurationWorksheet.pl --server reflex.primp-industries.com --username primp --output csv --hostlist hostlist
Enter password:
Processing vesx41-1.primp-industries.com
Generating vesx41-1.primp-industries.com.csv ...

Note: If you like to select the ESX hosts you want to report on, just create a file that has the displayname of your ESX host seperated by a newline

Here is sample report that you can view

You will notice that syslog section is left blank, this is done intentionally as with ESX, syslog configuration is not exposed through the vSphere API like ESXi. This will be something you will need to fill in manually.

I think this worksheet will be useful, but if you are interested in a more extensive report prior to upgrading, I would highly recommend you check out the popular vSphere Health Check script and here is what one of those reports can look like.

More from my site

  • An update on how to retrieve useful information from a vSphere login?
  • Do I need to install both the vSphere CLI & vSphere SDK for Perl?
  • Automate Enabling VM Storage Profiles Capability in vSphere
  • Automating VCSA Network Configurations For Greenfield Deployments
  • Retrieving vscsiStats Using the vSphere 5.1 API

Categories // Uncategorized Tags // ESXi 4.1, vsphere sdk for perl

Comments

  1. *protectedniall says

    06/13/2011 at 2:37 pm

    Hi Thanks for the script- v useful, what must I do however to run the script on an ESXi host?

    Reply
  2. *protectedWilliam says

    06/14/2011 at 4:47 am

    @niall,

    As the post mentions, you will need a system that has the vCLI installed or use VMware vMA

    Reply
  3. *protectedHilton Dagge says

    06/23/2011 at 2:34 pm

    Same problem for me, vCLI downloaded from your vmware website link will not accept the script against the non classic hosts.

    Reply
  4. *protectedWilliam says

    06/24/2011 at 1:13 am

    @Hilton,

    This script is for migration from ESX -> ESXi, if you're on ESXi, you shouldn't need to run this script 😉

    Reply
  5. *protectedHilton Dagge says

    06/24/2011 at 1:02 pm

    Thanks William I realise that, I was using it as a convienent way to gather info on my ESXi hosts, if you can't do it- no prob

    Reply
  6. *protectedWilliam says

    06/24/2011 at 2:03 pm

    @Hilton

    For that type of reporting, take a look at the vSphere Health Check script - http://communities.vmware.com/docs/DOC-9842

    Reply
  7. *protectedScott says

    07/04/2011 at 1:30 pm

    William,

    this is a great script. Is there a companion script that we can run to take the results from the original ESX host and use them to configure the replacement ESXi host?

    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

  • VCF 9.0 Hardware Considerations 05/30/2025
  • 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

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