Forum Discussion
Layer 7 load balancing
Can anyone pls suggest the best way to load balance layer 7 request with version 11. I have tried multiple combinations, even disabled cmp on the vip but it still only distributes based on the source ip. So requests from one source goes to one member and another to another pool member. We have 4 members but the other two are not utilized at all.
I think you've mislead yourself a bit. Unique client is determined by
combination, not just src-ip alone. If your clients share the same IP address, it's not a problem for the balancing results, unless you also use the SourceIP-based persistence method.src-ip:src-port
By default, BigIP balancing occurs once. Once a balancing decision is made, it is locked in which means all L7 requests thereafter will go to the same destination, unless specified otherwise by iRules/LTM policies. So the default is L4 balancing. This will work great for most cases.
In case of HTTP applications (or HTTPS if you do SSL offload in BigIP), you can get per-request-balancing by applying OneConnect profile to your Virtual Server. That would essentially be the L7 balancing you're looking for. OneConnect can significantly improve balancing results in case of low number of end-clients. However, in case of high number of end-clients, you can also get great balancing results without the use of OneConnect.
For best balancing results, general recommendation is to avoid the use of any persistence whenever possible. If the use of persistence cannot be avoided, universal or cookie persistence methods are preferred over SourceIP persistence.
Regards,
- ekaleidoCirrus
You need to gather something from the incoming request and use it in conjunction with a universal persistence profile. Hard to say what without any details.
Hello,
I suggest you to configure the "least connection member" loadbalancing method.
Then,I suggest you to add a cookie persistence profile to your Virtual Server. You can start with the default profile to test the behavior.
- Hannes_RappNimbostratus
I think you've mislead yourself a bit. Unique client is determined by
combination, not just src-ip alone. If your clients share the same IP address, it's not a problem for the balancing results, unless you also use the SourceIP-based persistence method.src-ip:src-port
By default, BigIP balancing occurs once. Once a balancing decision is made, it is locked in which means all L7 requests thereafter will go to the same destination, unless specified otherwise by iRules/LTM policies. So the default is L4 balancing. This will work great for most cases.
In case of HTTP applications (or HTTPS if you do SSL offload in BigIP), you can get per-request-balancing by applying OneConnect profile to your Virtual Server. That would essentially be the L7 balancing you're looking for. OneConnect can significantly improve balancing results in case of low number of end-clients. However, in case of high number of end-clients, you can also get great balancing results without the use of OneConnect.
For best balancing results, general recommendation is to avoid the use of any persistence whenever possible. If the use of persistence cannot be avoided, universal or cookie persistence methods are preferred over SourceIP persistence.
Regards,
- Hannes_RappNimbostratusYou may also benefit from URI/Path based L7 balancing. DevCentral can help with the iRules or LTM policies once you have the requirements in place. If interested, here's a relevant article on L7 switching: https://devcentral.f5.com/articles/making-the-most-of-your-ip-address-space-with-layer-7-switching
- Maverick_80689NimbostratusThanks guys, I still need to try the oneconnect profile but almost everything else has already been tested. Even without any persistence profile load balancing only happens based on the source-ip(maybe port too but it doesnt effect the results in our case). We cannot use an uri/path based irule because the uri remains the same. I did look at that layer-7 switching article but there is nothing there that applies to our requests. Will keep you posted.
- Hannes_Rapp_162Nacreous
I think you've mislead yourself a bit. Unique client is determined by
combination, not just src-ip alone. If your clients share the same IP address, it's not a problem for the balancing results, unless you also use the SourceIP-based persistence method.src-ip:src-port
By default, BigIP balancing occurs once. Once a balancing decision is made, it is locked in which means all L7 requests thereafter will go to the same destination, unless specified otherwise by iRules/LTM policies. So the default is L4 balancing. This will work great for most cases.
In case of HTTP applications (or HTTPS if you do SSL offload in BigIP), you can get per-request-balancing by applying OneConnect profile to your Virtual Server. That would essentially be the L7 balancing you're looking for. OneConnect can significantly improve balancing results in case of low number of end-clients. However, in case of high number of end-clients, you can also get great balancing results without the use of OneConnect.
For best balancing results, general recommendation is to avoid the use of any persistence whenever possible. If the use of persistence cannot be avoided, universal or cookie persistence methods are preferred over SourceIP persistence.
Regards,
- Hannes_Rapp_162NacreousYou may also benefit from URI/Path based L7 balancing. DevCentral can help with the iRules or LTM policies once you have the requirements in place. If interested, here's a relevant article on L7 switching: https://devcentral.f5.com/s/articles/making-the-most-of-your-ip-address-space-with-layer-7-switching
- Maverick_80689NimbostratusThanks guys, I still need to try the oneconnect profile but almost everything else has already been tested. Even without any persistence profile load balancing only happens based on the source-ip(maybe port too but it doesnt effect the results in our case). We cannot use an uri/path based irule because the uri remains the same. I did look at that layer-7 switching article but there is nothing there that applies to our requests. Will keep you posted.
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