Forum Discussion
navgup_66025
Nimbostratus
Aug 05, 2013irule and httpclass profile - what takes precedence?
In a VIP, i have added an irule-redir1 and httpclass-redir1 profile. Which one take precedence?
irule-redir1 has this:
when HTTP_REQUEST {
if { [HTTP::header exists "Authorization"] }...
nitass
Employee
Aug 05, 2013but it doesnot change the url on the browser and the pool is not selected.
that could be redirection rather than rewriting.
Redirects, Rewrites and App Transfers via iRules by Colin Walker
https://devcentral.f5.com/tech-tips/articles/redirects-rewrites-and-app-transfers-via-irules.UgB14m0-YdU
e.g.
[root@ve10:Active] config b virtual bar list
virtual bar {
snat automap
pool foo
destination 172.28.19.252:80
ip protocol 6
httpclass {
redirect-class
pool-class
}
profiles {
http {}
tcp {}
}
}
[root@ve10:Active] config b pool foo list
pool foo {
members 200.200.200.101:80 {}
}
[root@ve10:Active] config b pool qux list
pool qux {
members 200.200.200.111:80 {}
}
[root@ve10:Active] config b profile redirect-class list
profile httpclass redirect-class {
redirect "/test/index.asp"
paths "/test99"
}
[root@ve10:Active] config b profile pool-class list
profile httpclass pool-class {
defaults from httpclass
pool qux
redirect none
paths "/test/index.asp"
}
test
[root@ve10:Active] config ssldump -Aed -nni 0.0 port 80
New TCP connection 1: 172.28.20.17(51134) <-> 172.28.19.252(80)
1375761422.0567 (0.0010) C>S
---------------------------------------------------------------
HEAD /test99 HTTP/1.1
User-Agent: curl/7.15.5 (i686-redhat-linux-gnu) libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5
Host: 172.28.19.252
Accept: */*
---------------------------------------------------------------
1375761422.0569 (0.0001) S>C
---------------------------------------------------------------
HTTP/1.0 302 Found
Location: /test/index.asp
Connection: Keep-Alive
Content-Length: 0
---------------------------------------------------------------
1375761422.0584 (0.0015) C>S
---------------------------------------------------------------
HEAD /test/index.asp HTTP/1.1
User-Agent: curl/7.15.5 (i686-redhat-linux-gnu) libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5
Host: 172.28.19.252
Accept: */*
---------------------------------------------------------------
New TCP connection 2: 200.200.200.10(51134) <-> 200.200.200.111(80)
1375761422.0605 (0.0010) C>S
---------------------------------------------------------------
HEAD /test/index.asp HTTP/1.1
User-Agent: curl/7.15.5 (i686-redhat-linux-gnu) libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5
Host: 172.28.19.252
Accept: */*
---------------------------------------------------------------
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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