Closed spuder closed 6 years ago
Hi, Spencer, I can add an example to that function to help with that. It's expecting to get a PoolMember object passed to it. I.e. Get-poolmember -Name 'member1' | Get-PoolsForMember
Cheers, Joel
Thank you.
There appears to be two issues with that
This does not work
Get-PoolsForMember -Name 'foobar'
This does work
Get-PoolsForMember -Name 'foobar:80'
Get-PoolMember -F5Session $global:f5session -Name 'foobar:80' -Partition Common
Name Partition Address Description Monitor Session State
---- --------- ------- ----------- ------- ------- -----
foobar:80 Common 10.254.130.131 default monitor-enabled up
foobar:80 Common 10.254.130.131 default user-enabled unchecked
The work around for number 2 is to pipe to Unique
Hi, Spencer, as I mentioned in the other issue, my understanding is that pool members need to include port values in their names. That's an interesting point about multiple instances of the same pool member, if it's present in different pools. I think you're correct - if a name for a pool member is passed in, a unique result should be returned. I'm experimenting with having the results for Get-PoolMember be filtered for uniqueness before being returned.
Pull request made. Please review when you get a chance. Thanks.
Most functions take an array or a string. The Get-PoolsForMember takes a custom powershell object.
https://github.com/joel74/POSH-F5-BIGIP/blob/master/F5-BIGIP/F5-LTM/Public/Get-PoolsForMember.ps1#L11
Are there any examples of what the attributes of this custom powershell object should be?
If you pass a string to this function, you get this error