« Back to Microsoft Discussions

iSCSI boot using the initiator pool; powertool script not running

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
All, 
I am trying to create a service profile with iscsi boot vnics that use the iscsi-initiator-pool. I used convertto-ucscmdlet to generate a script while performing the tasks manually. The resulting script gave an error "

WARNING: Attempt to set non-existent property 'IdentPoolName' in class 'VnicIPv4If'.
WARNING: Attempt to set non-existent property 'IdentPoolName' in class 'VnicIPv4If'.
Complete-UcsTransaction : ucsm:XML PARSING ERROR: unknown attribute 'identPoolName' in element 'vnicIPv4If'
At C:\Users\johnken\Desktop\FlexPod Scripts\scripts\Add-IPMIAddresses.ps1:26 char:24
+ Complete-UcsTransaction <<<< 
    + CategoryInfo          : NotSpecified: (emoticon [Complete-UcsTransaction], Exception
    + FullyQualifiedErrorId : 300,Cisco.Ucs.Cmdlets.CompleteUcsTransaction

 
Sounds like the version I'm using doesn't have this property written in. 
Any idea how I can script this?
 

Start-UcsTransaction
$mo = Get-UcsOrg -Level root  | Add-UcsServiceProfile -AgentPolicyName "" -BiosProfileName "" -BootPolicyName "Boot-Fabric-A" -Descr "" -DynamicConPolicyName "" -ExtIPState "none" -HostFwPolicyName "VM-Host-Infra" -IdentPoolName "UUID_Pool" -LocalDiskPolicyName "default" -MaintPolicyName "" -MgmtAccessPolicyName "" -MgmtFwPolicyName "VM-Host-Infra" -Name "VM-Host_Infra_Fabric_A" -PowerPolicyName "default" -ScrubPolicyName "" -SolPolicyName "" -SrcTemplName "" -StatsPolicyName "default" -Type "updating-template" -UsrLbl "" -Uuid "0" -VconProfileName "VM-Host-Infra"
$mo_1 = $mo | Add-UcsVnicDefBeh -ModifyPresent -Action "none" -NwTemplName "" -Type "vhba"
$mo_2 = $mo | Add-UcsVnic -AdaptorProfileName "VMWare" -Addr "derived" -AdminVcon "1" -IdentPoolName "" -Mtu 1500 -Name "iSCSI-vNIC-A" -NwCtrlPolicyName "" -NwTemplName "iSCSI_Template_A" -Order "3" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A"
$mo_3 = $mo | Add-UcsVnic -AdaptorProfileName "VMWare" -Addr "derived" -AdminVcon "1" -IdentPoolName "" -Mtu 1500 -Name "iSCSI-vNIC-B" -NwCtrlPolicyName "" -NwTemplName "iSCSI_Template_B" -Order "4" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A"
$mo_4 = $mo | Add-UcsVnic -AdaptorProfileName "VMWare" -Addr "derived" -AdminVcon "1" -IdentPoolName "" -Mtu 1500 -Name "vNIC-A" -NwCtrlPolicyName "" -NwTemplName "vNIC_Template_A" -Order "1" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A"
$mo_5 = $mo | Add-UcsVnic -AdaptorProfileName "VMWare" -Addr "derived" -AdminVcon "1" -IdentPoolName "" -Mtu 1500 -Name "vNIC-B" -NwCtrlPolicyName "" -NwTemplName "vNIC_Template_B" -Order "2" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A"
$mo_6 = $mo | Add-UcsVnicFcNode -ModifyPresent -Addr "pool-derived" -IdentPoolName "node-default"
$mo_7 = $mo | Add-UcsVnicIScsi -ModifyPresent -AdaptorProfileName "default" -Addr "derived" -AdminVcon "any" -AuthProfileName "" -ConfProfileName "" -ExtIPState "none" -IdentPoolName "" -InitiatorName "" -IqnIdentPoolName "IQN_Pool_A" -Name "iSCSI-vNIC-A" -NwTemplName "" -Order "1" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A" -VnicName "iSCSI-vNIC-A"
$mo_7_1 = $mo_7 | Add-UcsVnicVlan -ModifyPresent -Name "" -VlanName "iSCSI-VLAN"
$mo_7_1_1 = $mo_7_1 | Add-UcsVnicIScsiStaticTargetIf -AuthProfileName "" -IpAddress $FAS_A_iSCSI_IP -Name $FAS_A_iSCSI_IQN -Port 3260 -Priority 1
$mo_7_1_1_1 = $mo_7_1_1 | Add-UcsVnicLun -ModifyPresent -Bootable "no" -Id 0
$mo_7_1_2 = $mo_7_1 | Add-UcsVnicIPv4If -ModifyPresent -Name ""
$mo_7_1_2_1 = $mo_7_1_2 | Set-UcsManagedObject -PropertyMap @{IdentPoolName="iscsi-initiator-pool"; }
$mo_8 = $mo | Add-UcsVnicIScsi -ModifyPresent -AdaptorProfileName "default" -Addr "derived" -AdminVcon "any" -AuthProfileName "" -ConfProfileName "" -ExtIPState "none" -IdentPoolName "" -InitiatorName "" -IqnIdentPoolName "IQN_Pool_B" -Name "iSCSI-vNIC-B" -NwTemplName "" -Order "2" -PinToGroupName "" -QosPolicyName "" -StatsPolicyName "default" -SwitchId "A" -VnicName "iSCSI-vNIC-B"
$mo_8_1 = $mo_8 | Add-UcsVnicVlan -ModifyPresent -Name "" -VlanName "iSCSI-VLAN"
$mo_8_1_1 = $mo_8_1 | Add-UcsVnicIScsiStaticTargetIf -AuthProfileName "" -IpAddress $FAS_A_iSCSI_IP -Name $FAS_A_iSCSI_IQN -Port 3260 -Priority 1
$mo_8_1_1_1 = $mo_8_1_1 | Add-UcsVnicLun -ModifyPresent -Bootable "no" -Id 0
$mo_8_1_2 = $mo_8_1 | Add-UcsVnicIPv4If -ModifyPresent -Name ""
$mo_8_1_2_1 = $mo_8_1_2 | Set-UcsManagedObject -PropertyMap @{IdentPoolName="iscsi-initiator-pool"; }
$mo_9 = $mo | Add-UcsServerPoolAssignment -ModifyPresent -Name "Infra_Pool" -Qualifier "" -RestrictMigration "no"
$mo_10 = $mo | Set-UcsServerPower -State "admin-down"
Complete-UcsTransaction

Thank you for your message, I am out of the office with limited access to e-mail. For urgent case please contact Luis Chang, I will be returning on Nov 20.

-James Tsao

John,
We have spotted a change that needs to be done in ConvertTo-UcsCmdlet to set this right.
The issue is with the below cmdlet in the set. There is caused because of a missing 'Set' Verb for an MO. 
$mo_8_1_2_1 = $mo_8_1_2 | Set-UcsManagedObject -PropertyMap @{IdentPoolName="iscsi-initiator-pool"; }
 
A fix would be available in 0.9.11.0
 
Thanks,
Vijay Vikrant Balyan