Forum Discussion
duffyj0_45477
Nimbostratus
Oct 20, 2010SOAP Response New to F5 - iRules
Is there a way to have an iRule to check 2 nodes in a pool, and that if they are both down. send this SOAP response?
HTTP/1.1 200 OK
Cache-Control: private
Content-length: 610
Content-Type: application/soap+xml; charset=utf-8
Server: Microsoft-IIS/7.5
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
http://www.w3.org/2005/08/addressing/soap/fault urn:uuid:318bb7b9-8ca6-4f9c-a094-a82f82109fc1 s:Sender The application is temporarily down for maintenance. "
- hoolio
Cirrostratus
... - JRahm
Admin
and use the LB::status command to check the pool member status: http://devcentral.f5.com/wiki/default.aspx/iRules/LB__status.html Click Here - hoolio
Cirrostratus
Hi Duffy,when HTTP_REQUEST { if {[active_members [LB::server pool]] == 0 }{ HTTP::respond 200 content \ {http://www.w3.org/2005/08/addressing/soap/fault urn:uuid:318bb7b9-8ca6-4f9c-a094-a82f82109fc1 s:Sender The application is temporarily down for maintenance. " } \ noserver \ Cache-Control private \ Content-Type {application/soap+xml; charset=utf-8} \ Server {Microsoft-IIS/7.5} } }
- duffyj0_45477
Nimbostratus
Thanks Guys! I'll get my guys to test and let you know how it goes. - hoolio
Cirrostratus
Posted By Jason Rahm on 10/20/2010 04:52 PM - JRahm
Admin
You can get this indirectly in GTM with the pools command, which returns a list or count of the pools in a particular color status. That might be a better namespace than LB::status as I take that to be a decision-based target of some sort, rather than a collection of targets. My $.02. Regardless of what it's called, that's a valuable bit of information and makes a lot of sense for enhancement. - duffyj0_45477
Nimbostratus
Hi All,
HTTP/1.1 200 OK - duffyj0_45477
Nimbostratus
HTTP/1.1 200 OK - hoolio
Cirrostratus
Can you clarify your question? Can you also put the code you want to return inside the [ code ] - duffyj0_45477
Nimbostratus
Thanks for all your help guys this has been resolved.
Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects