cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
901
Views
0
Helpful
5
Replies

New-UcsHardwareProfile help

Hello, I'm trying to use the following UCS power tool command to create a hardware profile to load into Cisco's online HCL tool here:  https://ucshcltool.cloudapps.cisco.com/public/#uploadedprofiles

Unfortunately all I've found is the syntax here:  Cisco UCS PowerTool Suite Installation and Configuration Guide, Release 2.x - Configure Cisco UCS PowerTool Suite [Cisc…

Its not clear what all the string variables should be however and its not real easy to understand how to figure out what they are.

5 Replies 5

raphaeltani
Level 1
Level 1

Hello;

I had same trouble to determine which <string> variable to take into account, after asking some support, the answer was to take the ID attribute of the object OsVendorCode and OsVersionCode

Below the UCS Hardware Profile object that worked for my case:

PS /> $uhp = New-UcsHardwareProfile -name test1 -ManagedObject $server -OsVendorCode $osv.ID -OsVersionCode $osvv.ID

Hope it helps

I am having the same issue but this answer does not clearly provide the exact syntax nor a complete example.  If possible can you provide a complete example.

admin11111
Level 4
Level 4

#These two commands list the info to put in the $osvID and $osVersion variables below

Get-UCSOSVendor

Get-UcsOperatingSystem -OsVendorTreeID 8 | sort osversion

$osvID = 8 

$osVersion = 722

$uhp = New-UcsHardwareProfile -name Test1 -ManagedObject (Get-UcsManagedObject -DN sys/chassis-2/blade-1) -OsVendorCode $osvID -OsVersionCode $osVersion

Use commands similar to below to explore the Hardware profile

$uhp.UcsServer

$uhp.UcsServer.Adapter

$uhp.UcsServer.Adapter.AdaptorHostEthIf

$uhp.UcsServer.BiosUnit.FirmwareRunning

$uhp.UcsServer.OS

Hope this helps

The vendor and OS codes need to be a proper values or the HardwareProfile cannot be uploaded to the HCLI Tool

$osVendorCode = 5

$osVersionCode = 624

$uhp = New-UcsHardwareProfile -name Codes-5-624 -ManagedObject (Get-UcsManagedObject -DN sys/chassis-2/blade-1) -OsVendorCode $osVendorCode -OsVersionCode $osVersionCode

Add-UcsHardwareProfile -Credential (get-Credential ListIS-InfrastructureServices1) -HardwareProfile $uhp

Get an error, can anyone help?:

1. seems OK:

PowerTool C:\> New-UcsHardwareProfile -name ucslab -ManagedObject (Get-UcsManagedObject -DN sys/chassis-1/blade-1) -OsVendorCode 8 -OsVers
ionCode 624

Name UcsServer
---- ---------
ucslab_0 Cisco.Ucs.Core.CiscoUcsServer

 

2. Error:

PowerTool C:\> Add-UcsHardwareProfile -Credential (get-Credential ListIS-InfrastructureServices1)

Cmdlet Add-UcsHardwareProfile an der Befehlspipelineposition 1
Geben Sie Werte für die folgenden Parameter an:
HardwareProfile: ucslab
Add-UcsHardwareProfile : Der Parameter "HardwareProfile" kann nicht gebunden werden. Der Wert "ucslab" vom Typ "System.String" kann
nicht in den Typ "Cisco.Ucs.Core.CiscoHardwareProfile" konvertiert werden.
In Zeile:1 Zeichen:1
+ Add-UcsHardwareProfile -Credential (get-Credential ListIS-Infrastruct ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Add-UcsHardwareProfile], ParameterBindingException
+ FullyQualifiedErrorId : CannotConvertArgumentNoMessage,Cisco.Ucs.Core.Cmdlets.AddUcsHardwareProfile

 

Review Cisco Networking for a $25 gift card