Forum Discussion
Dec 23, 2009
I cut and pasted your code directly from the post above and ran in in my PoolMemberControl.ps1 script and it worked.
PS C:\> .\PoolMemberControl.ps1 bigip user pass mypool 10.10.10.148:
80 disable
Disabling Session Enabled State...
Waiting for current connections to drop to zero...
Current Connections: 0
Disabling Monitor State...
Pool mypool, Member 10.10.10.148:80 status:
Availability : AVAILABILITY_STATUS_RED
Enabled : ENABLED_STATUS_DISABLED
Description : Forced down
Which version of PowerShell are you using? I'm working with v2.0 right now.
Try tossing in this line before the call to set_monitor_state():
MemberMonitorStateAofA.GetType();
It should print out something like this:
IsPublic IsSerial Name BaseType
-------- -------- ---- --------
True True LocalLBPoolMemberMemberMonitorState[][] System.Array
-Joe