When running API commands relating to SubVSs, sometimes you need to specify the SubVS using the SubVS ID (VSIndex) or Real Server ID (RsIndex).

The sections below provide an example of each scenario.

Add a Real Server to a SubVS

You can add a Real Server to a SubVS by using the New-AdcRealServer command. You must specify the Virtual Service ID (VSIndex) of the SubVS for this to work.

An example with output is provided below.

$newrs = New-AdcRealServer -RealServer 10.35.47.66 -RealServerPort 80 -VSIndex 3
$new | Format-List

ReturnCode : 200

Response : Command successfully executed.

Data :

Add a Content Rule to a SubVS

You can add a content rule to a SubVS by using the Add-NewAdcRealServerRule command. You must specify the Real Server ID (RsIndex) of the SubVS for this to work.

An example command with output is provided below.

$new = New-AdcRealServerRule -RuleName Test1 -RSIndex 1 -VirtualService 10.35.47.50 -VSPort 443 -VSProtocol tcp
$new | Format-List

ReturnCode : 200

Response : Command successfully executed.

Data :