Infrastructure Adventures

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.

05/18/2011

Understanding Citrix XenDesktop Machine Creation Services

Filed under: Compute, Virtualization — Tags: , , , , , , — Joe Keegan @ 3:09 PM

I’ve been trying to wrap my mind around XenDesktop’s Machine Creation Service (MCS). The documentation from Citrix is pretty terrible, but there is some good information out there on the web. This is my attempt to to take info from other sites and explain how XenDesktop MCS works.

Pooled vs. Dedicated

XenDesktop MCS can create two types of desktops:

  • Pooled desktops are the “disposable” stateless desktops that best practices dictate should make up most VDI deployments. Folder redirection, roaming profiles and the like are used to keep user data off the desktop’s hard disk image. Since user data is not stored on the desktop, the desktop is reset to it’s original state when a user logs out and in essence can be thrown away after each use. In this type of deployment a user can login to any desktop in the pool and get the same user experience since they “bring” all their data and profile settings with them.
  • Dedicated Desktops are similar to a traditional desktop deployment. Each user is assigned a desktop and it’s their desktop to love, cherish and potentially ruin. In this case all the changes made to a desktop are retained from session to session, and while using folder redirection/roaming profiles in dedicated desktops is till a best practice it is not required.  Since a dedicated desktop could be customized and contain data that is specific to that user then that user must always login to the same desktop.

MCS Overview

The following diagram gives an overview how Pooled and Dedicated desktops are provisioned by MCS.


It all starts with a VM which you plan to use as your Master Template. All the desktops in a catalog will be based off a Master Template. When creating the catalog you select the Master Template and choose if you want to create a pooled or dedicated desktop catalog.

MCS will then take a Private Snapshot and a public snapshot of the Master Template VM. The public snapshot is visible in the vSphere Client and is called Citrix_XD_CatalogName (Where CatalogName is the name of the catalog). The private snapshot is not visible via the vSphere client. The Public Snapshot can be removed without impacting the catalog and MCS.

Once the Private Snapshot is made then a Clone is created from that Snapshot. Each catalog will create it’s own snapshot and it’s own clone. So if you have two catalogs based on the same Master Template then you will have two clones. Also a clone is created for each data store included in that catalog. So if you have two catalogs each using the same five data stores then you will have ten clones, a clone for each catalog on each data store.

Each Desktop in a catalog is granted read only access to the clone on it’s data store. An Identity and a Difference vDisk are “layered” on top of the read only clone. The Identity vDisk includes all the specific desktop identity information such as host name, password, etc. The Difference vDisk is where all the writes and changes to the desktop are stored.  These Identity and Difference vDisks for each desktop are stored on the same data store as their related clone.

The difference between a Pooled or Dedicated desktop is what happens to the Difference vDisk when a user logs out.  In a dedicated desktop the differencing disk is retained after a user logs out while in a pooled desktop the differencing disk is deleted.

Updating Catalogs

One of the promises of VDI is to simplify desktop image management. This is usually handled by having the desktops share a master image. When the master is updated then all desktops using that master are updated also, usually just requiring a reboot. This is the case for MCS created pooled desktops, but not for dedicated desktops. The diagram below shows an overview of the updating process.

The Master Template has been updated and has been changed from the “Red” Image to the “Blue” Image.

To updated pooled desktops you select the “Update Machine” catalog option in Desktop Studio. You then point it at the new Master Template i.e. the “Blue” image. MCS then created the public and private snapshots and creates the clones. The pooled desktops are not updated until the restart, but when you “Update Machine” you can choose to do one of the following:

  • Nothing – The desktop will be updated whenever the user gets around to logging out, could be soon or could be a week from now.
  • Send a Message – A pop-up will display on the users desktop with a message that you can enter. Usually you ask a user to log off and back on when it’s convenient for them.
  • Reboot  - Do not pass go, just reboot it now. Not the most friendly thing to do to your users.
  • Send a Message and then Restart After a Delay – A pop-up will display on the users desktop with a message that you can enter. The desktop will the reboot in a set amount of time, defaulting to 1 hour.

In the meantime all new pooled desktops created from that catalog will use the new clone.

Dedicated desktops can not be updated like pooled desktops. Once a dedicated desktop is pointing to a clone it can not be changed. You can not even change the Master Template for a dedicated desktop catalog through the Desktop Studio, although you can with the following PowerShell command Publish-ProvMasterVmImage. if you do change the Master Template using the power shell command then all new desktops for that catalog will be based off the new “blue” image and clone, but the existing desktops will still be based off the old “red” clone.

Here are some links with MCS information:

http://www.thegenerationv.com/2011/03/xendesktop-5-deep-dive-machine-creation.html

http://forums.citrix.com/thread.jspa?messageID=1534982

http://support.citrix.com/article/CTX128328

05/03/2011

Installing the ProLiant Support Pack on Red Hat Enterprise Linux 6

Filed under: Compute — Tags: , , , — Joe Keegan @ 1:03 PM

I’m currently building a cluster of RHEL 6 systems on some HP hardware. This is my first time touching RHEL 6 and when I went to install the ProLiant Support Pack (PSP) on each of the systems I ran into some issues.

HP doesn’t actually have a version of the PSP for RHEL 6 yet, although the install instructions for the RHEL 5 version include install notes for RHEL 6. Frankly these notes are not adequate for someone who is not well versed in Linux package administration or someone who is rusty such as myself. I spent quite a while sorting out the install procedure and developed one that I though I would share. There seems to be others out there who are looking for this, so I hope this saves someone else a few hours.

– Install packages from Packages directory on the RHEL6 Media

rpm -i --nodeps libuuid-2.17.2-6.el6.i686.rpm
rpm -i --nodeps freetype-2.3.11-5.el6.i686.rpm
rpm -i --nodeps libSM-1.1.0-7.1.el6.i686.rpm
rpm -i --nodeps libICE-1.0.6-1.el6.i686.rpm
rpm -i --nodeps libXi-1.3-3.el6.i686.rpm
rpm -i --nodeps libX11-1.3-2.el6.i686.rpm
rpm -i --nodeps libXext-1.1-3.el6.i686.rpm
rpm -i --nodeps libxcb-1.5-1.el6.i686.rpm
rpm -i --nodeps libXau-1.0.5-1.el6.i686.rpm
rpm -i --nodeps libXrender-0.9.5-1.el6.i686.rpm
rpm -i --nodeps libXrandr-1.3.0-4.el6.i686.rpm
rpm -i --nodeps libXfixes-4.0.4-1.el6.i686.rpm
rpm -i --nodeps libXcursor-1.1.10-2.el6.i686.rpm
rpm -i --nodeps fontconfig-2.8.0-3.el6.i686.rpm
rpm -i --nodeps expat-2.0.1-9.1.el6.i686.rpm
rpm -i --nodeps zlib-1.2.3-25.el6.i686.rpm
rpm -i --nodeps libstdc++-4.4.4-13.el6.i686.rpm
rpm -i --nodeps net-snmp-libs-5.5-27.el6.i686.rpm
rpm -i --nodeps glibc-2.12-1.7.el6.i686.rpm
rpm -i --nodeps nss-softokn-freebl-3.12.7-1.1.el6.i686.rpm
rpm -i --nodeps libgcc-4.4.4-13.el6.i686.rpm
rpm -i --nodeps ncurses-libs-5.7-3.20090208.el6.i686.rpm
rpm -i tcl-8.5.7-6.el6.x86_64.rpm
rpm -i  expect-5.44.1.15-2.el6.x86_64.rpm

– Install HP Agents (from Smart Start CD under compaq/csp/linux directory)

rpm -i hp-health-8.7.0.22-16.rhel6.i386.rpm
rpm -i hp-snmp-agents-8.7.0.23-16.rhel6.i386.rpm

– Install version 8.70 of PSP
Note: The RPM Build for Qlogic iSCSI HBA will fail, unselect to install the rest. If you figure out how to get this installed please post in the comments and I will include.

– Reboot
– Add port 2381 to firewall rules

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

Follow

Get every new post delivered to your Inbox.

Join 32 other followers

%d bloggers like this: