Forum Discussion
theShell0x0_342
Nimbostratus
Nov 27, 2017VS in port different from node port
Hello,
I've a Virtual Server listining in a port 9444 and two nodes in port 9444 and 9447 when the node:9447 responde to the request the url port change as well, how to prevent this behavior? ...
Kai_Wilke
MVP
Nov 27, 2017Hi theShell0x0,
you may take a look to the iRule below. It uses the
HTTP_REQUEST_SEND event to enumerate the currently selected pool member and if the pool member IP matches a given criteria it will overwrite the requested HOST-header value to reflect the changed port number...
when HTTP_REQUEST_SEND {
if { [IP::server_addr] eq "1.2.3.4" } then {
clientside {
HTTP::host "vs-hostname:9447"
}
}
}
Note: Depending on the behaviour of your web application, it may be also required to parse the HTTP reponses (e.g. HTTP-Redirects, Links in HTML-Source) to untranslate the internal HOST-header value to reflect the external HOST-header value again.
Cheers, Kai
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
