How To – Install drivers in an ESXi Host
If you need to install drivers in an ESXi host, this is how you do it:
Recently I was building an ESXi host that used a CNA (Converged Network Adapter) for all network and storage, including for the management network. The specific card I was using was a QLogic QLE8262 CNA.
Normally if you don’t have a NIC driver, the installation will fail as it won’t detect a network card. In this instance however, I did have onboard NICs available, however in my environment these are not being used and hence had not been patched.
Once ESXi was built, I went to configure the Management Network, however there were no connected NICs in the network adapter settings of the Configure Management Network section in the DCUI. There are two solutions to this problem:
- Create a custom ESXi image with the correct drivers injected and then rebuild the host using the custom ESXi installer image
- Manually install the drivers via the DCUI
I went with option 2, however if you want to know how to create your own ESXi custom image, then I have documented it here >> How To – Create custom VMware ESXi Image
How To – Install drivers in an ESXi host
The following steps document how to install drivers into an ESXi host using the ESXi Shell from the DCUI. I had to do it this way as I didn’t have network access to the host (other than via out-of-band management).
If you have network access to your host, then you could simply do the install via SSH, following a similar process to the steps below but instead of mounting an ISO you could simply copy the drivers to the local datastore or something like that.
Here are the steps I took to resolve my issue:
- Enable ESXi Shell
- From the DCUI, press F2 to customise the system
- Enter your root credentials when prompted
- From the menu, select Troubleshooting Options
- Enable ESXi Shell
- From the DCUI, press Alt+F1 to access the ESXi Shell
- Log in with root credentials
- Using your out-of-band management attach the ISO that contains the drivers. If you don’t have an ISO file you can create one using the Img Burn software
- List all of the CD-ROMs available to ESXi by running
- Write down the results as you will need this later on. Note: You might see multiple results – document all of them. Example: mpx.vmhba33:C0:T0:L0
- Mount the ISO so that you can access the driver files, by running the following:
vmkload_mod iso9660 /sbin/vsish -e set /vmkModules/iso9660/mount mpx.vmhba33:C0:T0:L0
Note: If this doesn’t work try the other CDROMs from step 6
- Once successful, your CD-ROM will be mounted with the path of
/vmfs/volumes/. In my instance my CD-ROM mount path was /vmfs/volumes/DOWNLOADS
- If you are not sure what your CD-ROM label is, you find out by running:
- Next we need to install the drivers. To do this you will need to know the exact path to the driver and the name of the driver VIB file
- To install a driver in ESXi, run the following command:
esxcli software vib install -v /vmfs/volumes/DOWNLOADS/VMW_ESX_/QLNATIVE.VIB
- Repeat the above step to install any additional drivers you require
- Press Alt+F2 to exit the ESXi Shell
- You will now return to the DCUI. From here, reboot the host
And that is pretty much it. Hope this helps.