The upgrade season is here. VMware has released vSphere 6.7 and soon first backup/monitoring products will be compatible. Time to learn some tricks before Installation or upgrade on VMware ESXi. You know that with VMware ESXi hypervisor you can test an upgrade. I mean run the upgrade without actually upgrading, and see the result. It allows you to check whether an upgrade would create some compatibility problems or so. It's a good way to test, to preview the results, to see if your ESXi can actually be upgraded.
The option can only be executed through CLI so if you're planning to upgrade via VMware Update Manager (VUM) or upgrade via ISO, it won't work. You'll need an SSH access to your host and perform CLI upgrade. Well talk also about ESXi software profiles and how can we see details in each.
You can use the –dry-run option to preview the results of an installation or upgrade operation. A dry run of the installation or update procedure does not make any changes but reports the VIB-level operations that will be performed.
You can run this option when installing a whole upgrade package containing many individual VIBs or when you want to install a single VIB.
Tip: Check How-to Install VIB on ESXi host which teaches you what is VIB and how to install/uninstall.
We'll do a test run in the lab on it so we'll see how it goes.
How To do a Dry Run of an esxcli Installation or Upgrade on VMware ESXi – The steps
Step 1: Enable SSH and connect via Putty or another SSH client > put the host into a maintenance mode via
esxcli system maintenanceMode set –enable true
Step 2: Upload your update package to a datastore visible to your ESXi host and then execute your update command with an :
esxcli –server=server_name software profile install –dry-run
So in my test case
esxcli software profile update -p ESXi-6.7.0-8169922-standard -d /vmfs/volumes/datastore1/VMware-ESXi-6.7.0-8169922-depot.zip –dry-run
The output shows which VIBs will be installed or removed and whether the installation or update requires a reboot.
As you can see, we have a message that it's a “dry-run” only (not an actual installation/upgrade) and then there is the large list of vibs and drivers which will be installed.
Completely at the end, there is also a message which shows which VIBs will be skipped during the process.
How to list or remove a VIB?
you might want to ask how to remove a VIB?
To verify which VIBs are installed:
esxcli software vib list
To remove a VIB?
Yes, all VMware partners have hose third-party VIBs to provide management agents or asynchronously released drivers. Verify the documentation of such a driver, and you'll see that sometimes you'll need to uninstall and reboot particular driver before you can install a new one.
To Remove a vib, use this command:
esxcli –server=server_name software vib remove –vibname=name
You should always check:
if an upgrade/installation of a driver requires a reboot and the host is part of HA cluster, you should disable HA for the host and put the host in maintenance mode. This will evacuate all running VMs elsewhere.
You should care about network drivers as if you remove network driver you'll most likely loose connectivity. Either you can log in directly at the console or use another pNIC from another vendor to assure connectivity while you updating a driver of the other pNIC.
Interesting to know
You can use the –rebooting-image option to list the VIBs and profiles that are installed on the host and will be active after the next host reboot.
The command is like this for VIBs:
esxcli –server=server_name software vib list –rebooting-image
esxcli –server=server_name software profile get –rebooting-image
What's the Profile?
Each ESXi patch has several profiles, several versions. You can retrieve the versions via this command:
esxcli software sources profile list -d /vmfs/volumes/datastore1/VMware-ESXi-6.7.0-8169922-depot.zip
and we can deep deeper and see further details about a profile with this command:
esxcli software sources profile get -d /vmfs/volumes/datastore1/VMware-ESXi-6.7.0-8169922-depot.zip
As you can see, there are quite a few CLI commands which give us enough details about an update package, profile, or individual VIB. The “dry-run” command is useful in situations where you want to know and test an update/patch before actually doing it.
Remember, you still have the option during the boot process where you can revert back to the previous version, you can simply hold SHIFT + R and chose to roll back.
More from ESX Virtualization
- vSphere 6.7 Page
- Install and Configure VMware vCSA 6.7
- VMware vSphere 6.7 Security Features
- Top 5 Useful VMware ESXi CLI Commands
- What is vCenter Embedded Linked Mode in vSphere 6.7?
- VMware vSphere 6.7 and Enterprise Apps
- VMware vSphere 6.7 – vSphere Update Manager (VUM) HTML5 and Quick Boot
- VMware vSphere Essentials
- VMware vSphere Essentials Plus
- VMware vSphere Essentials Plus Kit Term
- VMware vSphere Essentials Kit Term