Forum Discussion
Kindly Guide How to add Error 500 alongwith Existing Error 503 into the Irule
Hi Jie,
🙂 True.. Our requirement is as below:
- In-case of any 500 or 503 error coming from destination member-servers, the mechanism is to make that server hard down and move to next server after trying 15 times before making it down. For this we have the below Irule which you assisted earlier:
when HTTP_REQUEST priority 700 { set my_url [HTTP::host][HTTP::uri] }
when HTTP_RESPONSE priority 700 { if { ( ( [HTTP::status] == 503 ) or ( [HTTP::status] == 500 ) ) && ( $count < 15 ) } { incr count HTTP::respond 302 Location "http://$my_url" event disable } elseif { ( ( [HTTP::status] == 503 ) or ( [HTTP::status] == 500 ) ) && ( $count == 15 ) } { set count 0
log local0. "Sending to Main Page" HTTP::respond 302 Location "http://www.xyz.com"
event disable
}
}
But to work this well, if not wrong : definitely we need to have some kind of advanced monitor which will track the 500 or 503 errors by some syntax of receive string from member-servers.
2.Currently the application member-servers as well as the APOLOGY-Page member-server( which is holding Maintenance-Page) is into the same pool.
For this we are planning to create Priority Activation Groups, where the application member-servers will hold a higher Priority Activation Group than the APOLOGY-Page member-server's Priority Group.
So, thats the reason we are looking for advanced monitor which can track the 500.* and 503.* errors from end member-servers.
Yes, we can go with Fallback host where we can specify the fallback errors( for eg 500;503), but this may hamper the existing concept of Irule which is tracking the errors: 500 and 503).
Thanks and Regards Parveez
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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