You can compare two image profiles by using the vSphere Client to check if they have the same VIB list, version, or acceptance level.

Prerequisites

Procedure

  1. Navigate to Home > Auto Deploy.
    By default, only the administrator role has privileges to use the vSphere ESXi Image Builder service.
  2. On the Software Depots tab, use the drop-down menu to select the software depot that contains the image profile that you want to work with.
  3. On the Image Profiles tab, select an image profile and click Compare To.
    The Compare Image Profile wizard appears.
  4. Click Change to select a second image profile.
    The Select Image Profile page appears.
  5. Select a software depot from the drop-down menu and click on the second image profile.
  6. In the Compare Image Profile page, select a comparison option from the Software packages drop-down menu.
    The left side of the list displays details of the VIBs that the first chosen image profile contains. The right part of the list provides information about the second image profile. The VIBs marked as Same are identical in both profiles. VIBs that are present in one of the image profiles are marked as Missing next to the image profile that they are not present in.

Compare Image Profiles with PowerCLI Cmdlets

You can compare two image profiles by using the Compare-EsxImageProfile cmdlet, for example, to see if they have the same VIB list or acceptance level . Comparing image profiles or their properties is also possible by using the PowerShell comparison operators.

Prerequisites

Install the PowerCLI and all prerequisite software. See Configure vSphere ESXi Image Builder.

Procedure

  1. In a PowerCLI session, run the Add-EsxSoftwareDepot cmdlet for each depot you want to work with.
    Option Action
    Remote depot Run Add-EsxSoftwareDepot -DepotUrl <depot_url>.
    ZIP file
    1. Download the ZIP file to a local file system.
    2. Run Add-EsxSoftwareDepot -DepotUrl C:\<file_path>\<offline-bundle>.zip
    The cmdlet returns one or more SoftwareDepot objects.
  2. (Optional) Run the Get-EsxImageProfile cmdlet to view a list of all image profiles in all available depots.
    In the list, you can locate the names of the image profiles you want to compare.
  3. Before comparing the image profiles, assign them to variables.
    For example, you can create variables $imageProfile1 and $imageProfile2 to hold the names of the compared images profiles.
    $imageProfile1
    				= Get-EsxImageProfile -Name "ImageProfile1"
    $imageProfile2
    				= Get-EsxImageProfile -Name "ImageProfile2"
  4. Compare the two image profiles by using the Compare-EsxImageProfile cmdlet or the -eq comparison operator, which returns a Boolean value.
    • Compare the two image profiles to get a full description of the differences by using the Compare-EsxImageProfile cmdlet.
      Compare-EsxImageProfile -ReferenceProfile
      					 $imageProfile1 -ComparisonProfile $imageProfile2
    • Compare the two image profiles by VIB list and acceptance level using the -eq comparison operator.
         if ($imageProfile1 -eq $imageProfile2) {
            Write-host "Successfully verified that both image profiles are equal."
         } else {
            Write-host "Failed to verify that the image profiles are equal."
         }
    • Compare the two image profiles by a specific property using the -eq comparison operator.
         if ($imageProfile1.vendor -eq $imageProfile2.vendor) {
            Write-host "Successfully verified that both image profiles are equal."
         } else {
            Write-host "Failed to verify that the image profiles are equal."
         }