Forum Discussion
How do you create an emtpy pool using powershell?
Im working on automating the VIP creation process and need to create empty pools then add the members later. So Im not certain how to create empty pools using powershell. Thanks.
2 Replies
You can try passing in empty values for the lb method and members in the Pool.create() method but that may error out. If it does, you can pass a single bogus member in and then issue a Pool.remove_member() call taking that member out.
- Will_Longo
Altostratus
I dont think you can create your pools with invalid or blank entries; but you can create a vip without a pool... try this.
$vipDefs = new-object "iControl.CommonVirtualServerDefinition[]" 1 $vipDefs[0] = new-object "iControl.CommonVirtualServerDefinition" $vipDefs[0].address = "0.0.0.0"; $vipDefs[0].name = $vipName $vipDefs[0].port = 0; $vipDefs[0].protocol = [iControl.CommonProtocolType]::PROTOCOL_ANY; $wildmask = @("0.0.0.0") $resources = new-object "iControl.LocalLBVirtualServerVirtualServerResource[]" 1 $resources[0] = new-object "iControl.LocalLBVirtualServerVirtualServerResource" $resources[0].default_pool_name = "" $resources[0].type = [iControl.LocalLBVirtualServerVirtualServerType]::RESOURCE_TYPE_IP_FORWARDING $profiles = new-object "iControl.LocalLBVirtualServerVirtualServerProfile[][]" 1 $iControl.LocalLBVirtualServer.create($vipDefs, $wildmask, $resources, $profiles)
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com