Search Me

Wednesday, July 6, 2011

Adding the HP Proliant Support Pack (PSP) to an OSD Task Sequence

The HP Proliant Support Pack, or PSP, can easily be addded to an SCCM OSD Task Sequence.   With a bit of customization, you can have the step install on all HP hardware and return a success back to SCCM. 

If you deploy with the PSP "out of the box", it may return a error code that doesn't translate to success in SCCM.  To get around that, we will use a batch file to do the work.

Here is the process:
  1. Create an "installation source" directory with all of your other packages.  Extract the PSP to this location.
  2. Create a new CMD file (I call it OSD_SilentInstall.cmd) and put it in this folder.  Copy the contents of the script below into this file and save it.  You should make any adjustments that are required at this point, but the script should work out of the box for just about any deployment scenario.
  3. In the SCCM console, create a new Package under Software Distribution.  I called it HP Proliant Support Pack v8.75, but the name is not important.  Specify the location you created in step one as the Installation Source.
  4. I feel the need to remind you to assign the package to a distribution point, replicated it, and make sure it replicated.  I can't tell you how many hours I've wasted over the years, just becuase I forgot to "update distribution points".  So -- do it now!
  5. Create a new program for this Package.  When chosing the executable, change the dropdown (lower right) to show all files.  Choose the CMD file that you created above.
  6. Edit your task sequence and create a new step called "HP ProLiant Support Pack".  Again, you can call it anything you want, the name isn't important.  This step should be an "Install Software" task available from Add > General > Install Software.  You should then choose the package you created in step 3 and select the installation program you created in step 5.
At this point, you're done.  It will install for all machines.  But what if you execute this sequence on non-HP hardware?  To add a restriction so it only installs on HP hardware:
  1. Open the Task Sequence back up and find the Task that you created to install the PSP. 
  2. Click on the Options Tab
  3. Click the Add Condition button and  choose WMI Query.  Enter the following query into the WQL Query text field and hit OK:

         Select * From Win32_ComputerSystem Where Manufacturer="HP"    
  4. Click OK.
Your sequence should now only apply to machines that identify themselves as having a Manufacturer of HP. 

As promised, here is the code for the batch file.  Most of it is not required, so you can feel free to edit out what you do not find necessary.  The important part is that your CMD script interpirt the result codes from the PSP and exit with the apropriate errorlevel.

:Init
  @Echo Off
  Cls
 
:Main
  Echo HP Proliant Support Pack
  Echo Source : %~dp0
  Echo ===============================================================================
  Echo Installing the HP Proliant Support Pack
  Echo Command: "%~dp0hpsum.exe" /use_latest /allow_non_bundle_components /express_install
  "%~dp0hpsum.exe" /use_latest /allow_non_bundle_components /express_install
 
:CheckForErrors
  Echo HP Proliant Support Pack Stauts:
  If "%errorlevel%"=="0" (
     Echo *******************************************************************************
  Echo                            INSTALLATION FAILED!
  Echo *******************************************************************************
  exit 1
  )
 
  If "%errorlevel%"=="1" (
     Echo Installation Successful!
     exit 0
  )
 
  If "%errorlevel%"=="2" (
     Echo Installation Successful, but a reboot is required.
     exit 0
  )
 
  If "%errorlevel%"=="3" (
     Echo Installation was canceled, or no components were updated
     exit 0
  )
 
  If "%errorlevel%"=="9009" (
     Echo Installation did not complete.  Check the path and make sure that the
  Echo Installation exists at the specified location:
  Echo Path: %~dp0
  Exit 1
  )
 
:End
  Echo An unknown status code was returned from the PSP.
  Echo This status code is [%errorlevel%].  This will be treated as a success,
  Echo but please check the installation to make sure it completedly properly!
  Exit 0

 
 

10 comments:

  1. Great blog Joe.

    We have been struggling with installing the PSP as part of an SCCM OSD task sequence, and your script has almost got us there.

    Strange thing is, it works fine when installing as an advertsisement, but for us will not run as part of the OSD?

    ReplyDelete
  2. When you say it doesn't run -- does the task not execute at all or can you not even add it to an OSD task?

    ReplyDelete
  3. I have the same problem. During the Task Sequence deployment of PSP it just hangs. I've tried several variations of HPSUM.exe syntax with no luck. Has anyone found a solution? I am running SCCM 2007 SP2 on a Windows 2003 SP2 server.
    Thanks Troy

    ReplyDelete
  4. Troy:

    The reason that the PSP fails is that it doesn't exit with normal error codes. So regardless of the syntax, the PSP will never complete successfully.

    Have you tried the deployment method I suggested in the article? The magic is the batch file that interprets the PSP exit codes and turns them into something usable by SCCM. It was the only way I could get it to work...

    ReplyDelete
  5. Wow! I wasn’t expecting such a quick response. Thanks Joe! I followed exactly what was in the article, down to copying and pasting the script straight out of the posting into a .cmd file called install.cmd. I saved this file in to same location of the PSP source code on the SCCM.

    ReplyDelete
  6. The PSP is rather temperamental, so it might actually take some investigation to figure out what is going on.

    When you create the program, the default timeout is 120 minutes. If something is hanging, it'll probably continue with an error after this timer expires. Unfortunately, we can't see what is happening on screen when the PSP is running, so we'd have to look for some log files or check the event log.

    My guess is you're going to have to stop a build right where it would install the PSP and then run it manually to see the results...

    I was fighting a machine the other day that was having problems. Turned out that the CPUs had different steppings and something in the PSP didn't like that. I had to actually pull one of the processors to get it to work right...

    ReplyDelete
  7. Thanks Joe...
    I ran the script manually and it works perfect. It just doesn't through SCCM. I'll keep chipping at it until I figure something out.
    Thanks again, Troy

    ReplyDelete
  8. Great article, thanks !

    I however ran into the same issue as Troy, when deploying during OSD the installation hangs.

    Troy: did you make any progress on this ?
    I could see the hpsum process still running with 0 CPU and ~42 Mb memory.

    ReplyDelete
  9. Hi,

    Just wondering if it worked during OSD, I have the same issue as it is not working during OSD Process, however it works fine when executed from command prompt.

    ReplyDelete
  10. In order to get this to work I had to change the install command to the following:

    "%~dp0hpsum.exe" /use_latest /allow_non_bundle_components /express_install /force:all /silent

    Worked perfect once I added /force:all and /silent

    ReplyDelete