Forum Discussion
LTM Policy to select pool based on TCP port is not working
The policy which Dario has posted above is what you want. If you can let us know in more detail what exactly is not working then that would help. For debugging purposes, I would add a log statement to show that you are hitting the ltm policy, maybe it is something else in the setup which is not working.
- MahiApr 02, 2020Cirrus
Hello Pete,
The solution of different virtual servers is what we tried and it worked. The design team want to reduce the number of virtual servers and use policies for some reason.
I am seeing a 'Reset' packet from the virtual server with the reason 'No server selected' in the packet capture. Somehow the policy is not kicking in. Any thoughts?
- PeteWhiteApr 02, 2020EmployeeHi Mahi, Can you either post your LTM policy here, or compare it to the example shown above.
- MahiApr 02, 2020Cirrus
ltm policy _WebApp_port_based_pool_selection { controls { forwarding } description "Pool selection based on destination port for WebApp only" last-modified 2020-04-02:08:28:15 requires { http tcp } rules { odessa.company.pvt { actions { 0 { forward select pool WebApp_odessa.company.pvt } } conditions { 0 { tcp port values { 40000 } } ordinal 2 } jasper.company.pvt { actions { 0 { forward select pool WebApp_jasper.company.pvt } } conditions { 0 { tcp port values { 40005 } } } } xyz.com { actions { 0 { forward select pool AzureWebApp_xyz } } conditions { 0 { tcp port values { 55000 } } } ordinal 1 } } status published strategy all-match } (END)
- PeteWhiteApr 02, 2020EmployeeI can see the problem – you are checking on the remote port, not the local port. In the rule, click the Options gear icon on the right and change it to local. Hit Done. Test it. Buy me a beer [cid:image001.jpg@01D60912.F1827B90]
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