Wednesday, November 23, 2016

How to Upgrade to ESXi 6.5 via command line using VMware Online Depot

VMware has recently released ESXi 6.5 and there is a quick and easy way of upgrading your ESXi hosts to the latest version using the command line and VMWare's online depot:

How to Upgrade to ESXi 6.5 via command line using VMware Online Depot

Using the VMware Online Depot is a simple way to upgrade if you only have 1 or 2 ESXi hosts to do, perfect for a small home lab setup.
  1. Place the host you want to upgrade into Maintenance Mode.
  2. Open PuTTY (or any other SSH client) and SSH into your host.
  3. Type the following command to open the firewall for outgoing HTTP requests:
    esxcli network firewall ruleset set -e true -r httpClient
  4. Type the following command to download and upgrade to the latest version of ESXi 6.5
    esxcli software profile update -d https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml -p ESXi-6.5.0-4564106-standard
  5. Now disable the HTTP firewall rule by typing:
    esxcli network firewall ruleset set -e false -r httpClient
  6. And finally, reboot the ESXi host to complete the upgrade.
    reboot
ESXi-6.5.0-4564106-standard is the first 6.5 release.

Tuesday, November 22, 2016

Fix slow disk performance (vmw_ahci driver) in ESXi 6.5

Update (27.03.2017) - the problem still exists for vmw-ahci version:

vmw-ahci 1.0.0-34vmw.650.0.14.5146846 

Update (01.08.2017) - the latest ESXi 6.5 update 1 (build 5969303) seems to fix the performance problems. Read below on how to upgrade your hosts...



VMWare recently released it's VSphere line versioned as 6.5. I do not recommend to install it yet in a production environment - but it should be fine for your homelab.

Im reading several blog posts about disk performance problems with the new standard AHCI-driver (native vmw_ahci driver). 

I noticed the problems when I started to deploy a new VM from an existing OVA and also when I moved a VM from one datastore to another (Max. Disk-read/write performance 10 MB/s). Also chrome uploaded the OVA with a max. speed of 16 MBit/s.

Older ESXi hosts were using the legacy vmklinux drivers and in general the new native drivers should offer a better performance and lower overhead as those are build directly for ESXi.

You can check if your adapters are using the native VMWare driver in the GUI by going to STORAGE -> ADAPTERS:




If you are experiencing slow disk performance you can disable the new native driver module and reboot your hosts (enable SSH and log in):

>> esxcli system module set --enabled=false --module=vmw_ahci

ESXi should fall back to the legacy ahci drivers and disk performance should be a lot better again.

On my hosts the OVA now uploaded at 300 MBit/s and Disk-read/write performance is back to the usual values.

You can also check if the module is enabled or disabled by running the following cli-command:

>> esxcli system module list


The affected module version for the native AHCI driver reports as:

vmw-ahci  1.0.0-32vmw.650.0.0.4564106  VMW  VMwareCertified   2016-11-20

Update (27.03.2017) - the problem still exists for vmw-ahci version:
vmw-ahci 1.0.0-34vmw.650.0.14.5146846 


Update (01.08.2017) - the latest ESXi 6.5 update 1 (build 5969303) seems to fix the performance problems.
It includes vmw-ahci 1.0.0-39vmw.650.1.26.5969303 

You can upgrade your ESXi 6.5 host by cli using the following commands:
esxcli network firewall ruleset set -e true -r httpClient
esxcli software profile update -p ESXi-6.5.0-20170702001-standard \
-d https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml
esxcli network firewall ruleset set -e false -r httpClient

Or download and boot the ESXi 6.5 Update 1 ISO to upgrade your host.

I hope this guide will help you until VMWare fixed the AHCI drivers for ESXI 6.5.