Forum Discussion
URI Based load balancing.
You can create an appropriate health monitor (http/https) and configure it to perform a check against the URI you have in mind e.g.
GET /your/path/file.php HTTP/1.1\r\nHost: my.domain.com \r\nConnection: Close\r\n\r\n
If you apply the monitor to your pool (ensure the members are configured to use the monitor). If a member is marked as being unhealthy because it fails the health check then new requests will be sent to an alternate pool member.
- Asif_Pasha_3042Jul 13, 2017Nimbostratus
Great!!! Thanks a ton. In my case there are nearly 20 URIs. Do I need to add them in sequence? GET /your/path/file1.php HTTP/1.1\r\nHost: my.domain.com \r\nConnection: Close\r\n\r\n GET /your/path/file2.php HTTP/1.1\r\nHost: my.domain.com \r\nConnection: Close\r\n\r\n GET /your/path/file3.php HTTP/1.1\r\nHost: my.domain.com \r\nConnection: Close\r\n\r\n and so on.... Kindly suggest
- RyannnnnnnnnJul 13, 2017Altocumulus
What is your requirement to check ~20 uri's?
- Asif_Pasha_3042Jul 13, 2017Nimbostratus
Customer complains that if one URI is having issue then the health monitor should mark it down. Else the traffic will still keep going to the same server again and again. Hence any URI among 20 may go down. so, we need to monitor them all. Kindly advice.
- RyannnnnnnnnJul 13, 2017Altocumulus
Ok. Without knowing the specifics about your infrastructure (and this is assuming that all your servers are running a single web server instance) but wouldn't it be fair to assume that if one uri failed the health check then all of them would fail?
An alternative may be to set up a specific health check page that for example performs a query against your underlying database and returns an expected result if healthy. That way you're checking end-to-end (database and web server).
- Samir_Jha_52506Jul 13, 2017Noctilucent
Use external monitor script to monitor all 20 web page.
-- create 20 URI monitor & assign to pool. Go to pool advance setting, add all monitor & select minimum monitor 20. If any one fail it will mark pool down 🙂Not tried option
- Asif_Pasha_3042Jul 13, 2017Nimbostratus
Thanks to both of you. Ryan, It looks more appropriate to check the underlying DB. Can you please share snippets to create the irule for SQL DB if you have any? Thanks again.
- Samir_Jha_52506Jul 13, 2017Noctilucent
Try this link. Change select condition based on requirement. All the best
 
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