How to change iLO IP from ESXi

I ran into an issue at work, where the iLO lost all its settings after a hardware intervention. The host was running fine and the iLO NIC was connected, but the IP configuration was missing. Because this is a remote site, it would be easy if the configuration could be set from within ESXi. Luckily, this is a possibility!

Installing the tools

The first thing we need to do is download the VIB from the HPE website. You can find the tools if you search for “HPE Utilities Offline Bundle”. Download the latest zip file, for your specific version of ESXi, and upload it somewhere on your ESXi host.

Next, install the bundle using this command;

esxcli software vib install -d /tmp/HPE-Utility-Component_6.5.0.10.7.1-8.zip

The result will look something like this

Installation result

Reboot the host after the installation. Once the host is back, you can verify that it is installed by running the following command. The output should look like the picture below.

esxcli software vib list | grep hpon*
Verify if software is installed

Listing iLO configuration

Now that we have the tool available, we can check the current configuration of the iLO. First, change the directory to /opt/tools, which is where the tool is installed to. Next, run the following command to export the active config to a txt file.

./hponcfg -w /tmp/ilocfg.txt

Looking at the exported configuration, you can immediately see what’s wrong, in our case the iLO configuration is completely empty.

iLO configuration

Changing the iLO configuration

To change the configuration, we can just make the required changes to the exported configuration file. Just use vi to make the required changes.

Once you’re satisfied with the new config, you can apply it by running this command

./hponcfg -f /tmp/ilocfg.txt

You should be able to reach the iLO on the configured IP address. There’s just one more step to do, and that is to reset the administrator password.

To do this, we’ll create a new xml file with the config to reset the admin password. Just create a new file and give it a name that you want, here we’re using admin.xml. The contents of the file look like this

<ribcl VERSION="2.0">
    <login USER_LOGIN="Administrator" PASSWORD="SuperS3curePass!>
        <user_INFO MODE="write">
            <mod_USER USER_LOGIN="Administrator">
                <password value="SuperS3curePass!" />
            </mod_USER>
        </user_INFO>
    </login>
</ribcl> 

Now we just apply the config file, like we did before;

./hponcfg -f /tmp/admin.xml

Once the configuration is successfully applied, verify that you can access iLO with the new password. If it works, make sure you delete the admin.xml file as this contains the password in clear text!


Update ESXi fails with dependency error vmkapi_2_0_0_0

In the past few weeks, I’ve been in the process of updating several standalone ESXi hosts to 6.5. As you would expect, everything went smooth up to a certain point. Several hosts started failing and throwing this error:

VIB LSI_bootbank_scsi-megaraid-perc9_6.901.55.00-1OEM.500.0.0.472560 requires vmkapi_2_0_0_0, but the requirement cannot be satisfied within the ImageProfile.
VIB LSI_bootbank_scsi-mpt3sas_04.00.00.00.1vmw-1OEM.500.0.0.472560 requires com.vmware.driverAPI-9.2.0.0, but the requirement cannot be satisfied within the ImageProfile.

The entire error is shown below.

At first, I thought it was something with the image I was using. That’s why I also tried with the vanilla VMware image. Sadly, the same error popped up. Trying different zip files also did not solve the issue. I began looking into how I could make vmkapi 2.0 available on the host. Turns out that there’s not a whole lot written about this.

I started looking at the command again when I remembered there’s also another way I could install the update. When using esxcli to update, you can also use esxcli software profile install command. The update command updates existing VIBs with the ones that are in the specified profile, all the other VIBs aren’t touched. While the esxcli software profile install command installs all the VIBs present in the image profile, it will also remove any other VIBs installed on the server.

When I ran the install command everything proceeded without any issues. Here’s the command I used;

esxcli software profile install -p DellEMC-ESXi-6.5U3-14320405-A03 -d /vmfs/volumes/datastore/ISO/VMware-VMvisor-Installer-6.5.0.update03-14320405.x86_64-DellEMC_Customized-A03.zip --ok-to-remove

You can also add the –dry-run switch to get a list of VIBs that will be removed, before you actually change anything.