Forum Discussion
crush09_18103
Aug 21, 2012Nimbostratus
Redirect
So this is what I'm trying to do... We have a production webpage (virtual server/pool) with basic health monitors. We have a maintenance webpage (virtual server/pool). So the application guys wa...
nitass
Aug 21, 2012Employee
e.g.
172.28.19.79 is production virtual
200.200.200.101 is production pool
172.28.19.89 is maintenance virtual
[root@ve10:Active] config b virtual prod list
virtual prod {
snat automap
pool prodpool
destination 172.28.19.79:80
ip protocol 6
rules myrule
profiles {
http {}
tcp {}
}
}
[root@ve10:Active] config b pool prodpool list
pool prodpool {
monitor all myhttp
members 200.200.200.101:80 {}
}
[root@ve10:Active] config b monitor myhttp list
monitor myhttp {
defaults from http
dest 172.28.19.89:80
reverse
recv "down"
send "GET /test.html HTTP/1.1\r\nHost: \r\nConnection: Close\r\n\r\n"
}
[root@ve10:Active] config b rule myrule list
rule myrule {
when HTTP_REQUEST {
if {[active_members [LB::server pool]] < 1} {
HTTP::fallback "http://172.28.19.89"
}
}
}
[root@ve10:Active] config curl http://172.28.19.89/test.html
down
[root@ve10:Active] config b pool prodpool|grep -i pool
POOL prodpool LB METHOD round robin MIN/CUR ACTIVE MEMBERS 0/0
+-> POOL MEMBER prodpool/200.200.200.101:80 inactive,down
[root@ve10:Active] config curl -I http://172.28.19.79
HTTP/1.0 302 Found
Location: http://172.28.19.89
Connection: close
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