Intel,Altiris Group

PowerShell Module for Intel vPro Technology 

May 19, 2011 11:49 AM

Over two years ago, I posted a short piece on Scripting Intel AMT Power-on.   That article referred to an Intel AMT SDK utility called remotecontrol.exe.

If we fast forward to the present day, there's a better and more functional approach.   Take a look at the PowerShell Module for Intel vPro Technology

Commonly referred to as the vPro PowerShell Module, or vPSM, this handy tool provides a number of capabilities that may not be exposed within Symantec Management Platform, Altiris 7.1, Workflow, etc.   If you are still on Deployment Server 6.9, the vPSM may be very useful for the initial power-on of the client.

You will need the Windows Remote Management installed on your system.   Specifically, the WinRM component since vPSM using webservice manageability (WS-MAN) to communicate with the clients.

More information on installing and setting up vPSM is in the PDF document included with the download.

In addition to the rich set of features\capabilities exposed via the vPSM - there's a piece I really like for scripting purposes.   If you are using Digest authentication, a master Digest account and password can be securely stored as an encrypted string accessible only by the powershell cmdlet environment.   This effectively allows a lead IT administrator to set the Intel AMT credentials without having to share the details with others.

Steps to set a master Intel AMT digest credential:

  • Start PowerShell on your system (i.e. powershell.exe)
  • Within the powershell command prompt, import the IntelvPro module (i.e. Import-Module IntelvPro)
  • Assign the credentials to $amtcred (i.e. $amtcred = Get-Credential)
  • The above command will open a windows username\password prompt.   Enter the digest username and password accordingly.
  • Assign the credentials to a secure store (i.e. Write-AmtCredential -Username $amtcred.UserName -Password $amtcred.Password)

Now you can access the secure storage while calling a batch file from a regular windows command prompt.  This will use the piping\pipeline capabilities of PowerShell.

To do this:

  • Create a BAT file such as "Power on Machine.bat"
  • Add one line to the batch file
    • powershell -command "& {import-module IntelvPro; $amtcred = read-amtcredential; invoke-amtpowermanagement %* -credential $amtcred -operation:PowerOn"}
  • Save the file

Now you are ready to call the batch script with a system name or IP address.

As an example:

  • "c:\power on machine.bat" 192.167.1.105

Will do the following:

This is just a beginning.  Take a look at the commands available with vPSM.  (i.e. Get-Command -Module IntelvPro     <-- run this within a PowerShell command prompt with IntelvPro module loaded.   More information on each module is available via help screens or in the PDF document provided with vPSM)

Happy scripting!

The opinions expressed on this site are mine alone and do not necessarily reflect the opinions or strategies of Intel Corporation or its worldwide subsidiaries 

Statistics
0 Favorited
0 Views
0 Files
0 Shares
0 Downloads

Tags and Keywords

Comments

Aug 07, 2013 06:01 AM

never mind my last comment. The Powershell profile was in the wrong folder and was therefore not loaded.

I use the command powershell -file ".\Intel AMT\Powershell\PowerOn.ps1" %COMPNAME% and run it locally from deployment server.

My PowerOn ps1 file:

param([String[]] $Compname)
invoke-amtpowermanagement $Compname -credential $amtcred -operation:PowerOn | % {if ($_.status -eq "Successful") {exit 1234} ELSE {exit 1235}}

 

Jul 29, 2013 08:33 AM

I can't get this working when I select "locally on the deployment server" on the DS powershell the job is finished instantly and the command is not executed.

I tried different ways to run the script; direct from the ds using the embedded field, run script directly from bat file, run bat files from another bat file, run from exe file, nothing seems to work. Process monitor tells me powershell is opened with the correct command line but the script is done instantly.

The only way it works is when I execute the script manually.

Related Entries and Links

No Related Resource entered.