If you not using VMware Update Manager but you have mulitple ESX/ESXI servers managed by vCenter server you should install and configure it, as it will save you a so much time and its so simple.
However if you have hosts that are not managed by vCenter server or the odd standalone host you need a way of installing updates from VMware as they are released to ensure security compliance and system reliability.


The best way I find of updating a standalone host is to use the VMware vSphere CLI.

1. If you dont have VMware vSphere CLI, download and install it onto your client PC
http://www.vmware.com/support/developer/vcli/


2. Download your required patches (Always only get direct from VMware)
http://www.vmware.com/patch/download/
You can also subscribe to email alerts when updates are released.


3. Put the ESX/ESXi host into Maintenance Mode
If there are any VMs running on the host you will need to shut them down and power them on another host (If possible). I assume they cannot be vMotioned to another host as this would require vCenter, in which case why aren't you using VMware Update Manager?! Its free with vCenter.


3. Open a VMware vSphere CLI command prompt
C:\Program Files (x86)\VMware\VMware vSphere CLI\bin>


4. Run the vihostupdaye.pl script to update the host with the downloaded file.

C:\Program Files (x86)\VMware\VMware vSphere CLI\bin>
vihostupdate.pl -i -b c:\Temp\ESXi410-201010001.zip --server=thunder
Enter username: root
Enter password:
Please wait patch installation is in progress ...
The update completed successfully, but the system needs to be rebooted for the changes to be effective.

 

5. Your will see in the vSphere client the update is installed on the host.

 
 
 
 
 









6. Reboot your ESX/ESXi host
Job done. You will now see the build number has changed on that host to confirm the update the update has been installed.



NOTE: If you fail to put the host into maintenance mode you will see the error below and it will not allow the update to install:
vihostupdate.pl -i -b c:\Temp\ESXi410-201010001.zip --server=thunder
Enter username: root
Enter password:
Please wait patch installation is in progress ...
Maintenance mode is not enabled or could not be determined.The following VIBs require this host to be in maintenance mode: deb_vmware-esx-firmware_4.1.0-0.1.320092. Please put the host in maintenance mode to proceed.





C:\Program Files (x86)\VMware\VMware vSphere CLI\bin>vihostupdate.pl -help
 
Synopsis: C:\Program Files (x86)\VMware\VMware vSphere CLI\bin\vihostupdate.pl OPTIONS
 

Command-specific options:
   --bulletin
    -B
 
             Parameter to specify the selective bulletin(s) to install. Use
             comma to specify multiple bulletins (eg. bulletin1,bulletin2).
             All bulletins will be installed if this option is not specified.
 
   --bundle
    -b
 
             Parameter to specify the location of the offline bundle.  For install operation, multiple
             offline bundles can be specified using comma separator with no space (eg. bundle1,bundle2).
 
   --install
    -i
 
             Install the host with selective bulletins from the bundle, the depot or local offline bundle.
 
   --list
    -l
 
             List the bulletins in the bundle or in the depot.
 
   --metadata
    -m
 
             Parameter to specify the location of the depot metadata.zip
 
   --nosigcheck
    -c
 
             Ignore integrity checking during install operation (unsupported).
 
   --query
    -q
 
             Query the bulletins that are already installed in the host.
 
   --remove
    -r
 
             Remove selective bulletins from the host.
 
   --scan
    -s
 
             Scan the host against the bundle or the depot for applicable bullet
ins.
 

Common VI options:
   --config (variable VI_CONFIG)
      Location of the VI Perl configuration file
   --credstore (variable VI_CREDSTORE)
      Name of the credential store file defaults to <HOME>/.vmware/credstore/vicredentials.xml on Linux and <APPDATA>/VMware/credstore/vicredentials.xml on Windows
   --encoding (variable VI_ENCODING, default 'utf8')
      Encoding: utf8, cp936 (Simplified Chinese), iso-8859-1 (German), shiftjis(Japanese)
   --help
      Display usage information for the script
   --passthroughauth (variable VI_PASSTHROUGHAUTH)
      Attempt to use pass-through authentication
   --passthroughauthpackage (variable VI_PASSTHROUGHAUTHPACKAGE, default 'Negotiate')
      Pass-through authentication negotiation package
   --password (variable VI_PASSWORD)
      Password
   --portnumber (variable VI_PORTNUMBER)
      Port used to connect to server
   --protocol (variable VI_PROTOCOL, default 'https')
      Protocol used to connect to server
   --savesessionfile (variable VI_SAVESESSIONFILE)
      File to save session ID/cookie to utilize
   --server (variable VI_SERVER, default 'localhost')
      VI server to connect to. Required if url is not present
   --servicepath (variable VI_SERVICEPATH, default '/sdk/webService')
      Service path used to connect to server
   --sessionfile (variable VI_SESSIONFILE)
      File containing session ID/cookie to utilize
   --url (variable VI_URL)
      VI SDK URL to connect to. Required if server is not present
   --username (variable VI_USERNAME)
      Username
   --verbose (variable VI_VERBOSE)
      Display additional debugging information
   --version
      Display version information for the script

 

Share this blog post on social media:

Social Links

Disclaimer

All advice, installation/configuration how to guides, troubleshooting and other information on this website are provided as-is with no warranty or guarantee. Whilst the information provided is correct to the best of my knowledge, I am not reponsible for any issues that may arise using this information, and you do so at your own risk. As always before performing anything; check, double check, test and always ensure you have a backup.

Copyright ©2008-2021 Andy Barnes - Please do not copy any content including images without prior consent!

Designed and Hosted by Andy Barnes

We use cookies

We use cookies on our website. Some of them are essential for the operation of the site, while others help us to improve this site and the user experience (tracking cookies). You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.