While VMware Tools ISO images on ESXi hosts are typically managed via the VMware ESXi installer, vSphere Update Manager (VUM), or vSphere Lifecycle Manager (vLCM), they can also be installed and updated manually.
For more information about upgrading VMware Tools using vSphere Lifecycle Manager on vSphere 7.0, see Upgrade the VMware Tools Version of Virtual Machines
This article provides:
This article also helps in resolving the errors or issues:
The VMware ESXi installer, vSphere Update Manager (VUM), and vSphere Lifecycle Manager (vLCM) manage VMware Tools ISO image files in the default /locker/packages/vmtoolsRepo
partition. It is strongly advised against manually updating the contents of this default repository. Doing so can cause conflicts with automated lifecycle management operations. This article focuses on placing the productlocker on a different location.
The /productLocker
symbolic link determines the active VMware Tools repository. Its target is controlled by the UserVars.ProductLockerLocation advanced setting, found in:
/productLocker
points to /locker/packages/vmtoolsRepo
. However, when a ramdisk cache is in use, /productLocker
may point to /tools
. # ls -l /productLocker
# readlink /productLocker
When installing VMware Tools repository on a datastore for the first time, you first need to create a directory to use as the root of the repository.
The datastore location for the repository and the directory must be only for use as the VMware Tools ISO images repository (i.e.: not a Virtual Machine folder or home)
1. Create the VMware Tools repository on the datastore, and adjust the permissions:
# mkdir /vmfs/volumes/<datastore-name-or-volume-id>/<vmtools-repository-name>
# chmod 700 /vmfs/volumes/<datastore-name-or-volume-id>/<vmtools-repository-name>
2. If the VMware Tools repository has content, it is recommended to empty it rather than overwriting existing files.
3. Download and extract the VMware Tools packages from Broadcom Support
4. Update the VMware Tools repository content (pick one of):
Option 1
Copy the “vmtools” and “floppies” sub-directories from the extracted directory to the VMware Tools repository.
# cp -r /path-to-package-extracted-dir/vmtools /vmfs/volumes/<datastore-name-or-volume-id>/vmtools-repository-name>/
# cp -r /path-to-package-extracted-dir/floppies /vmfs/volumes/<datastore-name-or-volume-id>/vmtools-repository-name>/
Option 2
Selectively update the VMware Tools ISO images files. To provide VMware Tools to Windows VMs take the following files from the (latest) VMware-Tools-windows zip and put them into the respective folders "vmtools" and "floppies":
vmtools/isoimages_manifest.txt
vmtools/isoimages_manifest.txt.sig
vmtools/windows.iso
vmtools/windows.iso.sha
vmtools/windows.iso.sig
vmtools/windows_avr_manifest.txt
vmtools/windows_avr_manifest.txt.sig
floppies/pvscsi-Windows8.flp
floppies/pvscsi-Windows2008.flp
floppies/pvscsi-WindowsVista.flp
Option 3
If you want to provide VMware Tools for legacy Linux guest operating systems as well, additionally take the following files from the (latest) VMware-Tools-core zip and put them into the "vmtools" folder.
vmtools/linux.iso
vmtools/linux.iso.sha
vmtools/linux.iso.sig
vmtools/linux_avr_manifest.txt
vmtools/linux_avr_manifest.txt.sig
4. Set the required permissions for the files:
# chmod -R 700 /vmfs/volumes/<datastore-name-or-volume-id>/vmtools-repository-name>/*
Note: All steps here-on (step 5 and following) are for first-time setup of the vmtools repository on a shared datastore or when the location of the vmtools repository changes.
5. Configure ProductLocker to use the new VMware Tools ISO images repository location. To update the UserVars.ProductLockerLocation setting to the VMware Tools ISO images repository location using a method below.
# esxcli system settings advanced set -o /UserVars/ProductLockerLocation -s /vmfs/volumes/<datastore-name-or-volume-id>/vmtools-repository-name>
Host > Manage > Advanced Settings
Host > Configure > Advanced System Settings (search for UserVars.ProductLockerLocation)
6. Update the ProductLocker symbolic link (/productLocker) with of the following methods
Note: Using this approach is not recommended for ESXi hosts that are provisioned using Auto Deploy. For more information on configuring host profile for hosts provisioned with Auto Deploy, see VMware Tools for hosts provisioned with Auto Deploy (2004018).
https://vcenter_fqdn/mob
. Login with the [email protected]
account, then browse to [content > rootFolder > childEntity > hostFolder]. Follow the path under childEntity until you arrive at the host.Alternatively you can open the API directly using the Host ID. For this, select the host in vSphere Client. The URL will include the ID as shown in the picture below:
Use this ID to open the following URL:
https://vcenter_fqdn/mob/?moid=<ID>&method=updateProductLockerLocation
In the example this would be:
https://vcenter_fqdn/mob/?moid=host-18022&method=updateProductLockerLocation
Click on "Invoke Method" to apply the setting:
Following VMware ESXi host reboot, the entry for the productLocker in the VMware ESXi security policies will be updated to the new path. This update can fail if the datastore becomes accessible later than expected in the VMware ESXi host boot process. As a result, VMs security policies do not have the updated productLocker location and the VMware Tools repository is not accessible to the running VMs.
To detect the issue, Inspect the security policies:
# secpolicytools -d | grep $(basename $(readlink /productLocker)) | cut -d' ' -f2 | head -n1
-r <absolute-path-to-vmtoolsRepo-on-datastore> r
If the above path does not match, you need to reload the security policies:
# secpolicytools -p
Any running VM will need to be vMotion’d to a different host and back, or shutdown (reset will not work) and then powered on for the change to take effect. VM powered on after the security policies are updated will have the correct VMware Tools repository access.
Note: The datastore being slow to become accessible during VMware ESXi host reboot should be investigated, it could be linked to a storage or other resource issues in the environment.