Infrastructure Adventures

02/26/2012

vSphere Auto Deploy and HP Servers

Filed under: Compute, Virtualization — Tags: , , , , — Joe Keegan @ 7:57 PM

HP’s Online Software Depot

HP has a bunch of software that can be included in an ESXi install such as System Insight Manager (SIM) agents. These agents are normally installed by using ESXi installation media made available by HP. But in an Auto Deploy scenario  you’ll need to use the vSphere Image Builder PowerCLI to add the HP agenets to your image profiles.

The really awesome thing is that HP has created an online depot where you can get these agents all within the frame work of Image Builder. You can take a look at the depot here:  http://vibsdepot.hp.com, but honestly there isn’t much to look at with a web browser. For the real value you need to add the site as an ESX Software Depot.

PS>add-EsxSoftwareDepot http://vibsdepot.hp.com/index.xml
Depot Url
---------

http://vibsdepot.hp.com/index.xml

PS>Get-EsxSoftwarePackage -Newest | Select-Object Name,Vendor,Summary

Name                    Vendor                       Summary
----                    ------                       -------
hpnmi                   hp                           hpnmi for ESXi 5.0
char-hpilo              Hewlett-Packard              hpilo: char driver for VMware ESX
char-hpcru              Hewlett-Packard              hpcru: char driver for VMware ESX
hpbootcfg               Hewlett-Packard              HP ProLiant Boot Configuration Utility for ESXi
hponcfg                 Hewlett-Packard              HP ProLiant Lights-Out Configuration Utility for ESXi
hp-smx-provider         Hewlett-Packard              HP Insight Management WBEM Providers for ESXi

Above we can see that there are several software packages available in the online depot. In typical HP fashion the vendor name isn’t consistent across all the packages, so just be aware that some are hp while others are Hewlett-Packard. Also not every single VIB from HP is available via this site, such as the 3PAR VAAI Plug-in. Hopefully all of HP’s VIB will be available via this site in the future.

Building an Image Profile with the HP Agents

Below is an example script of using the Image Builder PowerCLI to copy the latest ESXi image profile from VMware’s online depot and then adding all of the HP packages to that image.

# Add VMware's Online Depot so we can get the latest Image Profiles and Software Packages
Add-EsxSoftwareDepot https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml
# Add HP's Online Depot to get access to all of HP's Software Packages
add-EsxSoftwareDepot http://vibsdepot.hp.com/index.xml

# Vars used to set the ESXi image profile name, basically just a time stamped name
$DATESTAMP=get-date -Format yyy.M.d
$PROFILEAME="ESXi-HP_$DATESTAMP"

# Sort the image profiles from VMware's online depot to get the latest image profile
$ImageProfiles = Get-EsxImageProfile | Where-Object {$_.name -like "*standard*"} | Sort-Object "ModifiedTime" -Descending

# Create a copy of the latest image profile from VMware's online depot
New-EsxImageProfile -CloneProfile $imageprofiles[0] -name $PROFILEAME

# Add the HP related packages to the our new image profile
Get-EsxSoftwarePackage -vendor "Hewlett-Packard" | Add-EsxSoftwarePackage -ImageProfile $PROFILEAME
Get-EsxSoftwarePackage -vendor "hp" | Add-EsxSoftwarePackage -ImageProfile $PROFILEAME

# Export the image profile to a bundle
Export-EsxImageProfile -ImageProfile $PROFILEAME -ExportToBundle -FilePath c:\$PROFILEAME.zip

Even if you are not using Auto Deploy you can still use HP’s Online Depot to build your own installation media.  Simply replace the -ExportToBundle in the Export-EsxImageProfile cmdlet to -ExportToISO, and make sure to change the file extension to .iso.

Other Drivers

The HP ESXi installation media includes several driver packages in addition to the HP Agents. These are drivers for Emulex and Mellanox cards that are not included in VMware’s base ESXi image profile. I wasn’t able to figure out a way to add an online depot to access these packages via the Image Builder CLI. These are not needed for every installation, but if they are needed for your installation then you are going to need to download the drivers from the VMware download site and add them via their offline bundles.

For example after downloading the VMware ESXi50 Driver for Emulex iSCSI Driver from VMware’s download site, I extract the zip and get the following.

I then need to add the offline bundle included in the download as an ESX Software Depot so that I can add these software packages to my custom image. The following shows the commands needed to load the offline bundle, view the included software packages, load my custom image profile and to add the packages to my custom image.


PS>Add-EsxSoftwareDepot C:\Depot\be2iscsi-4.0.317.0-offline_bundle-469760.zip
Depot Url
---------
zip:C:\Depot\be2iscsi-4.0.317.0-offline_bundle-469760.zip?index.xml
PS>Get-EsxSoftwarePackage

Name          Version                       Vendor     Release Date
----          -------                       ------     ------------
ima-be2iscsi  4.0.317.0-1OEM.500.0.0.406165 Emulex ... 7/26/2011 6:4...
scsi-be2iscsi 4.0.317.0-1OEM.500.0.0.406165 Emulex ... 7/26/2011 6:4...

PS>Add-EsxSoftwareDepot C:\Depot\ESXi-5.0-Lab_20120225.zip
Depot Url
---------
zip:C:\Depot\ESXi-5.0-Lab_20120225.zip?index.xml

PS>Get-EsxSoftwarePackage -Vendor "*Emulex*" | Add-EsxSoftwarePackage -ImageProfile ESXi-5.0-Lab_20120225
Name                  Vendor       Last Modified   Acceptance Level
----                  ------       -------------   ----------------
ESXi-5.0-Lab_20120225 VMware, Inc. 2/26/2012 6:... PartnerSupported
ESXi-5.0-Lab_20120225 VMware, Inc. 2/26/2012 6:... PartnerSupported

Again you’ll want to use the Export-EsxImageProfile cmdlet to save the image profile as an offline bundle or to create an ISO.

Hopefully VMware will make these 3rd party drivers available via an online software depot or the other 3rd party vendors follow HP’s lead and make their own online depots.

02/13/2012

3Par VAAI Plug-In and VMware Auto Deploy

Filed under: Storage, Virtualization — Tags: , , , , , , — Joe Keegan @ 10:36 AM

Just a quick post on using the HP 3PAR Software Plug-In for VMware VAAI with VMware Auto Deploy. The process should be pretty much the same for adding any other plugin.

1.) Download the VAAI 2.2 Plugin form HP

Get it here – HP 3PAR Software Plug-In for VMware VAAI (If the link is dead just Google for it)

2.) Load your depot & add the FDM

I use an offline depot so I load it and the FDM (VMware’s Failover Domain Manager – i.e. VMware HA).

Add-EsxSoftwareDepot <Offline Depot Path>
Add-EsxSoftwareDepot http://<vCenter Server>/vSphere-HA-depot
Add-EsxSoftwarePackage -ImageProfile "<ImageProfile>" -SoftwarePackage vmware-fdm

3.) Add the 3Par VAAI Plug-in

The Plug-in is located in a zip file, the one I downloaded from HP is called VMware_VAAI_2.2_QL227_10502.zip, yours should have the same or similar name. Then add the zip as a depot and and add the plug-in to your image profile.

Add-EsxSoftwareDepot C:\Depot\VMware_VAAI_2.2_QL227_10502.zip
Add-EsxSoftwarePackage -ImageProfile "<ImageProfile>" -SoftwarePackage 3PAR_vaaip_InServ

4. Create Deploy Rule

Create the deploy rule to use the image profile that includes the Plug-in.

New-DeployRule -Name <Rule Name> -Item "<ImageProfile>",<Host Profile>,<Cluster> -Pattern <Patern>
Add-DeployRule -DeployRule <Rule Name>

5. Edit the Host Profile

The ESXi server needs to know to load the plug-in and this is accomplished through the host profile applied to server.

Edit the host profile and drill down to Storage configuration –> Pluggable Storage Architecture (PSA) configuration –> PSA claimrule number  and then select Add Profile. This will add a psa_psaProfile_PsaClaimrulesProfile.

Expand the psa_psaProfile_PsaClaimrulesProfile to show the Claim information and the Claim type. Click on the Claim information and enter the following information.

That’s 5001 for Rule Number, VAAI_Filter for PSA plugin name and filter for claimrule class.

The click on claim type and enter the following.

That’s 3PARdata for the Vendor name and * for the Model.

Now create another psa_psaProfile_PsaClaimrulesProfile by right clicking and selecting add profile again. Enter the following for the Claim information.

That’s 5001 for Rule Number, 3PAR_VAAIP_INSERV for PSA plugin name and VAAI for claimrule class.

Then enter the same info you entered above for the Claim type. That’s 3PARdata for the Vendor name and * for the Model.

As an aside, I got this information by creating a host profile from an ESXi host that had the plugin installed and working. I looked through that host profile and pulled out this info.

Now hit OK to save the host profile and you should be good to go. Once you provision another host via Auto Deploy using this host profile you should see VAAI working for your 3PAR LUNs. You can check this by validating that Hardware Acceleration for these LUNs show supported.

05/26/2011

Expanding a Master Volume on a HP P2000 G3 Array

Filed under: Storage — Tags: , , , , , , — Joe Keegan @ 4:37 PM

A master volume on a P2000 G3 array is a volume that has the ability to have snapshots. If the volume is created via the GUI as “snappable” then the volume is automatically created as a master volume. Likewise if you add snapshots to the volume sometime after the volume has been created it is automatically converted into a master volume.

The issue around master volumes is that they can not be expanded. In the GUI that option is simply grayed out. To expand the master volume you will need to login to the P2000 via SSH and use the CLI to:

  1. Remove any snapshots
  2. Convert the master volume into a standard volume
  3. Expand the volume
  4. Expand the snap pool (optional)
  5. Convert the volume back into a master volume

The steps to accomplish this is covered below for an example volume called Web with a snap pool called spWeb.

# show volumes
Vdisk Name             Size    Serial Number                     WR Policy     Cache Opt        Read Ahead Size  Type         Class    Qualifier
  Volume Description
---------------------------------------------------------------------------------------------------------------------------------------
vd01  Web              99.9GB  00c0ff10a5ce00000102db4d01000000  write-back    standard         Default          master volumePTSNAP
  N/A
vd01  spWeb            19.9GB  00c0ff10a5ce0000dbe3de4d01000000  write-back    standard         Default          snap pool    PTSNAP
  N/A
----------------------------------------------------------------------------------------------------------------------------------
Success: Command completed successfully.

First we should check if there are any snapshots

# show snapshots
Vdisk Serial Number                     Name      Creation Date/Time        Status             Status-Reason        Source Volume Snap-pool Name
  Snap Data  Unique Data  Shared Data  Priority   User Priority   Type                                                                   

----------------------------------------------------------------------------------------------------------------------------------
vd01  00c0ff10a5ce0000bce2de4d01000000  Web_s001  2011-05-26 23:31:08       Available          N/A                  Web
  spWeb          393.2KB    393.2KB      0B           0x6000     0x0000
  Standard snapshot
----------------------------------------------------------------------------------------------------------------------------------
Success: Command completed successfully.

There is one snapshot called Web_s001 which we should delete using the following command. Of course once the snapshot is deleted any unique data contained within the snapshot will be lost.

# delete snapshot Web_s001 cleanup
Info: Snapshot Web_s001 was deleted. (Web_s001)

Success: Command completed successfully.

The cleanup argument will convert the master volume into a standard volume if the last snapshot for that volume is deleted. We can now see that the Web volume is a standard volume.

# show volumes
Vdisk Name             Size    Serial Number                     WR Policy     Cache Opt        Read Ahead Size  Type         Class    Qualifier
  Volume Description
---------------------------------------------------------------------------------------------------------------------------------------
vd01  Web              99.9GB  00c0ff10a5ce00000102db4d01000000  write-back    standard         Default          standard     standard
  N/A
vd01  spWeb            19.9GB  00c0ff10a5ce0000dbe3de4d01000000  write-back    standard         Default          snap pool    PTSNAP
  N/A

If you have multiple snapshots you can just run this command for each snapshot or you can use the command below to delete all snapshots for a volume.

# delete all-snapshots volume Web
Info: This may take a few minutes if the system is under heavy load...
Success: Command completed successfully. (Web) - All snapshots were deleted.

This command does not have a cleanup argument so you will need to manually convert the master volume into a standard volume like so.

# convert master-to-std Web
Success: Command completed successfully. (Web) - The conversion of a master volume to a standard volume completed.

Now we are ready to expand the Web volume. In this example we add another 100GBs to the volume.

# expand volume size 100GB Web
Success: Command completed successfully. - Expansion of volume Web was started.

# show volumes
Vdisk Name             Size    Serial Number                     WR Policy     Cache Opt        Read Ahead Size  Type         Class    Qualifier
  Volume Description
---------------------------------------------------------------------------------------------------------------------------------------
vd01  Web              199.9GB 00c0ff10a5ce00000102db4d01000000  write-back    standard         Default          standard     standard
  N/A
vd01  spWeb            19.9GB  00c0ff10a5ce0000dbe3de4d01000000  write-back    standard         Default          snap pool    PTSNAP
  N/A
---------------------------------------------------------------------------------------------------------------------------------------
Success: Command completed successfully.

We can now see that the Web volume is 199.9GB instead of 99.9GB.

Expanding the volume does not expand the snap pool for the volume. Depending on your needs you may want to increase the snap pool to match the same ratio that existed before. In our case the snap pool was 20% of the Web volume’s original size so we will increase the snap pool so it remains 20% (i.e. we are going to increase it to around 40GBs).

# expand snap-pool size 20GB spWeb
Success: Command completed successfully. (spWeb) - Expansion of volume spWeb was started.

# show volumes
Vdisk Name             Size    Serial Number                     WR Policy     Cache Opt        Read Ahead Size  Type         Class    Qualifier
  Volume Description
---------------------------------------------------------------------------------------------------------------------------------------
vd01  Web              199.9GB 00c0ff10a5ce00000102db4d01000000  write-back    standard         Default          standard     standard
  N/A
vd01  spWeb            39.9GB  00c0ff10a5ce0000dbe3de4d01000000  write-back    standard         Default          snap pool    PTSNAP
  N/A
---------------------------------------------------------------------------------------------------------------------------------------
Success: Command completed successfully.

Lastly we need to convert the volume back into a master volume.

# convert std-to-master snap-pool spWeb Web
Success: Command completed successfully. (Web) - The conversion of a standard volume to a master volume completed.

# show volumes
Vdisk Name             Size    Serial Number                     WR Policy     Cache Opt        Read Ahead Size  Type         Class    Qualifier
  Volume Description
---------------------------------------------------------------------------------------------------------------------------------------
vd01  Web              199.9GB 00c0ff10a5ce00000102db4d01000000  write-back    standard         Default          master volumePTSNAP
  N/A
vd01  spWeb            39.9GB  00c0ff10a5ce0000dbe3de4d01000000  write-back    standard         Default          snap pool    PTSNAP
  N/A
---------------------------------------------------------------------------------------------------------------------------------------
Success: Command completed successfully.

While it’s not great that you have to blow away all your snapshots to expand a volume, at least it’s not too difficult to accomplish the task.

Older Posts »

The Silver is the New Black Theme. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.

Join 37 other followers

%d bloggers like this: