-
Notifications
You must be signed in to change notification settings - Fork 52
Add HPOVResourceToRack
Add supported resource to rack.
Add-HPOVResourceToRack [-InputObject] <Object> [-Rack] <Object> [-ULocation] <Int32>[ [-ApplianceConnection] <Object>] [<CommonParameters>]
Add a supported resource to a rack resource object.
-ApplianceConnection <Object>
Aliases [-Appliance]
Specify one or more HPOneView.Appliance.Connection object(s) or Name property value(s).
Default Value: ${Global:ConnectedSessions} | ? Default
Aliases | Appliance |
Required? | false |
Position? | named |
Default value | (${Global:ConnectedSessions} | ? Default) |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | False |
-InputObject <Object>
The suppported resource object from. Supported resource objects are: *Enclosures *Servers *Unmanaged Devices
Aliases | None |
Required? | true |
Position? | named |
Default value | |
Accept pipeline input? | true (ByValue) |
Accept wildcard characters? | False |
-Rack <Object>
The Rack object from Get-HPOVRack.
Aliases | None |
Required? | true |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | False |
-ULocation <Int32>
The rack unit location where the resource is located.
Aliases | None |
Required? | True |
Position? | named |
Default value | 0 |
Accept pipeline input? | false |
Accept wildcard characters? | False |
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, PipelineVariable, and OutVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216)
HPOneView.Facilities.Rack [System.Management.Automation.PSCustomObject]
Rack resource object from Get-HPOVRack.
HPOneView.Facilities.Rack [System.Management.Automation.PSCustomObject]
Updated DataCenter object with the newly added Rack resource in the contents property.
-------------------------- EXAMPLE 1 --------------------------$Rack = Get-HPOVRack -Name MyRack221 -ErrorAction Stop $Servers = Get-HPOVServers -Name Prod221* -ErrorAction Stop $_U = 1 ForEach ($Server in $Servers) { Add-HPOVResourceToRack -InputObject $Server -Rack $Rack -ULocation $_U $_U += $Server.formFactor.Replace("U",$null) }
Add "Prod221" (DL) servers to "MyRack221" rack object, starting at Rack U 1, and increasing the location based on the form factor of the DL servers.
-------------------------- EXAMPLE 2 --------------------------$Rack = Get-HPOVRack -Name MyRack222 -ErrorAction Stop $Enclosures = Get-HPOVEnclosures -Name Encl-Prod* -ErrorAction Stop | ? rackName -eq $Rack.name $_U = 1 ForEach ($Enclosure in $Enclosures) { Add-HPOVResourceToRack -InputObject $Enclosure -Rack $Rack -ULocation $_U $_U += 10 }
Add Enclosures which the Onboard Administrators report are in "MyRack222", and add them to "MyRack222" rack object, starting at Rack U 1, and increasing the location by 10U.
Add supported resource to rack.
Add-HPOVResourceToRack [-InputObject] <Object> [-Rack] <Object> [-ULocation] <Int32>[ [-ApplianceConnection] <Object>] [<CommonParameters>]
Add a supported resource to a rack resource object.
-ApplianceConnection <Object>
Aliases [-Appliance]
Specify one or more HPOneView.Appliance.Connection object(s) or Name property value(s).
Default Value: ${Global:ConnectedSessions} | ? Default
Aliases | Appliance |
Required? | false |
Position? | named |
Default value | (${Global:ConnectedSessions} | ? Default) |
Accept pipeline input? | true (ByPropertyName) |
Accept wildcard characters? | False |
-InputObject <Object>
The suppported resource object from. Supported resource objects are: *Enclosures *Servers *Unmanaged Devices
Aliases | None |
Required? | true |
Position? | named |
Default value | |
Accept pipeline input? | true (ByValue) |
Accept wildcard characters? | False |
-Rack <Object>
The Rack object from Get-HPOVRack.
Aliases | None |
Required? | true |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | False |
-ULocation <Int32>
The rack unit location where the resource is located.
Aliases | None |
Required? | True |
Position? | named |
Default value | 0 |
Accept pipeline input? | false |
Accept wildcard characters? | False |
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, PipelineVariable, and OutVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216)
HPOneView.Facilities.Rack [System.Management.Automation.PSCustomObject]
Rack resource object from Get-HPOVRack.
HPOneView.Facilities.Rack [System.Management.Automation.PSCustomObject]
Updated DataCenter object with the newly added Rack resource in the contents property.
-------------------------- EXAMPLE 1 --------------------------$Rack = Get-HPOVRack -Name MyRack221 -ErrorAction Stop $Servers = Get-HPOVServers -Name Prod221* -ErrorAction Stop $_U = 1 ForEach ($Server in $Servers) { Add-HPOVResourceToRack -InputObject $Server -Rack $Rack -ULocation $_U $_U += $Server.formFactor.Replace("U",$null) }
Add 'Prod221' (DL) servers to 'MyRack221' rack object, starting at Rack U 1, and increasing the location based on the form factor of the DL servers.
-------------------------- EXAMPLE 2 --------------------------$Rack = Get-HPOVRack -Name MyRack222 -ErrorAction Stop $Enclosures = Get-HPOVEnclosures -Name Encl-Prod* -ErrorAction Stop | ? rackName -eq $Rack.name $_U = 1 ForEach ($Enclosure in $Enclosures) { Add-HPOVResourceToRack -InputObject $Enclosure -Rack $Rack -ULocation $_U $_U += 10 }
Add Enclosures which the Onboard Administrators report are in 'MyRack222', and add them to 'MyRack222' rack object, starting at Rack U 1, and increasing the location by 10U.