esxcli software vib commands to patch an ESXi 5.x/ 6.xhost (2008939)-Alibaba Cloud Developer Community

https://kb.vmware.com/selfservice/microsites/search.do? language=en_US&cmd=displayKC&externalId=2101199

 

to use the command line to repair the ESXi 5.x/ 6.x host, perform the following operations:

  1. patches for VMware products can be obtained from VMware patch portal. Select from the product drop-down list ESXi (embedded and installable) , and then click search .

  2. Click patch version name downloaded download link to download the patch to the system.

  3. Use from vCenter data storage browser alternatively, you can use the vSphere Web Client to upload the patch to the data storage of the ESXi 5.x/ 6.x host by directly connecting to the ESXi 5.x/ 6.x host. Small : VMware recommends that you create a new directory in data storage and upload the patch files to this directory.

  4. Log on to the local technical support mode console of the ESXi 5.x/ 6.x host. For more information, see Using Tech Support Mode in ESXi 4.1 and ESXi 5.x (1017910).

  5. Migrate the running virtual machines on the host or turn off their power to place the host in maintenance mode. You can run the following command to place the host in maintenance mode from the command line: # vim-cmd hostsvc/maintenance_mode_enter

  6. navigate to the directory where the patch file uploaded in data store is located and run the following command to verify that the file exists: # cd /vmfs/volumes/ Datastore / DirectoryName # ls where, Datastore is the name of the data store where the uploaded patch file is located, DirectoryName the directory you created in the data store.

  7. Use the following esxcli command to install or update patches on the host small :

    small : The installation method may overwrite existing drivers. If third-party ESXi images are used, VMware recommends using an update method to avoid unguided status.

    Mounting : update :

  • use the local installer: # esxcli software vib update -d "/vmfs/volumes/ Datastore / DirectoryName / PatchName.zip " where, PatchName.zip is the name of the patch file uploaded to the data store. Small : Alternatively, you can use the UUID of the data store instead. DirectoryName . Example: # esxcli software vib update -d "/vmfs/volumes/datastore1/patch-directory/ESXi500-201111001.zip" or # esxcli software vib update -d "/vmfs/volumes/a2bb3e7c-ca10571c-cec6-e5a60cc0e7d0/patch-directory/ESXi500-201111001.zip"

  • use http to install the program: # esxcli software vib update -v viburl  where, viburl is the URL pointing to the http library where the VIB package is located. Example: # esxcli software vib update -v https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/esx/vmw/vib20/tools-light/VMware_locker_tools-light_5.0.0-0.7.515841.vib

  • use the local installer: # esxcli software vib install -d "/vmfs/volumes/ Datastore / DirectoryName / PatchName.zip " where, PatchName.zip is the name of the patch file uploaded to the data store. Small : Alternatively, you can use the UUID of the data store instead. DirectoryName . Example: # esxcli software vib install -d "/vmfs/volumes/datastore1/patch-directory/ESXi500-201111001.zip" or # esxcli software vib install -d "/vmfs/volumes/a2bb3e7c-ca10571c-cec6-e5a60cc0e7d0/patch-directory/ESXi500-201111001.zip"

  • use http to install the program: # esxcli software vib install -v viburl  where, viburl is the URL pointing to the http library where the VIB package is located. Example: # esxcli software vib install -v https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/esx/vmw/vib20/tools-light/VMware_locker_tools-light_5.0.0-0.7.515841.vib

  • To install or update .zip file, please use -d optional. To install or update .vib file, please use -v optional.

  • We recommend that you use the update command to apply the patch. Use this command to apply all updates in the patch, including all security patches. The content of the patch version earlier than the version of the existing software package in the system will not be applied.

  • Use install the command overwrites existing software packages in the system with the content of the patch you are installing, including installing new software packages and removing old software packages. Installation commands may degrade software packages in the system and should be used with caution. If necessary, when --allow-downgrade when marking, you can use the installation command to downgrade the system (only applicable to image configuration files).

Verify that VIB is installed on the ESXi host:# esxcli software vib list

for example,# esxcli software vib list

Name Version Vendor Acceptance Level Install Date ----------------- ------------------------------------------------------------------ ------ ---------------- ------------

ata-pata-amd 0.3.10-3vmw.500.0.0.469512 VMware VMwareCertified 2012-05-04

ata-pata-atiixp 0.4.6-3vmw.500.0.0.469512 VMware VMwareCertified 2012-05-04

ata-pata-cmd64x 0.2.5-3vmw.500.0.0.469512 VMware VMwareCertified 2012-05-04

ata-pata-hpt3x2n 0.3.4-3vmw.500.0.0.469512 VMware VMwareCertified 2012-05-04

after installing the patch, reboot the SMB host:

# reboot

after the host boot is complete, exit the maintenance mode and power on the virtual machine:

# vim-cmd hostsvc/maintenance_mode_exit

this article is forwarded from the 51CTO blog of Xuehai boundless blog, the original link http://blog.51cto.com/549687/1898691如需转载请自行联系原作者

520feng2007

Please read this disclaimer carefully before you start to use the service. By using the service, you acknowledge that you have agreed to and accepted the content of this disclaimer in full. You may choose not to use the service if you do not agree to this disclaimer. This document is automatically generated based on public content on the Internet captured by Machine Learning Platform for AI. The copyright of the information in this document, such as web pages, images, and data, belongs to their respective author and publisher. Such automatically generated content does not reflect the views or opinions of Alibaba Cloud. It is your responsibility to determine the legality, accuracy, authenticity, practicality, and completeness of the content. We recommend that you consult a professional if you have any doubt in this regard. Alibaba Cloud accepts no responsibility for any consequences on account of your use of the content without verification. If you have feedback or you find that this document uses some content in which you have rights and interests, please contact us through this link: https://www.alibabacloud.com/campaign/contact-us-feedback. We will handle the matter according to relevant regulations.
Selected, One-Stop Store for Enterprise Applications
Support various scenarios to meet companies' needs at different stages of development

Start Building Today with a Free Trial to 50+ Products

Learn and experience the power of Alibaba Cloud.

Sign Up Now