Forum Discussion
Irule bassed on html
Hi, i have a monitor string that look into serveralive.html, if he recieve 1 than he send the request to the server on the pool, so if i want to do some working on the server all connection will go to another one on the pool by changing the serveralive.html value to 0 . what i want to do is an irule that will let me move traffic to that pool even if my both serveralive.html file will send 0, can i do it?
thats how i will get full pritection for my mistakes :)
16 Replies
- Hi Alakata,
- Hi Aaron
- You can use iRule to select a pool member based on the certain condition.
http://devcentral.f5.com/wiki/default.aspx/iRules/pool.html
- I think I misunderstood what you were trying to do. I think you could do something like what you've described using an iRule which checks if the virtual server's default pool has no active members and selects a secondary pool in that case.
when CLIENT_ACCEPTED { Save the name of the virtual server's default pool before it is potentially changed by this iRule set default_pool [LB::server pool] } when HTTP_REQUEST { Check if the virtual server pool is down if {[active_members $default_pool] == 0 }{ Select an alternate pool pool second_pool } }
- well thanks, i guess that this is what i was after :)
- I think you need something more specific than just "1" to look for in the response. It's quite likely that "1" would be found in the response headers. Can you use curl to check the response from the server when the value is 0 and 1 and post the anonymous output here?
- i will,
- Every HTTP response will have a 1 in the headers:
- I guess I will try it but can you please tell me what do you mean
- Actually, can you try this:
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