Forum Discussion
samir_110997
Nimbostratus
Apr 16, 2007Redirect trafic http to specific pool member and ftp trafic to another pool member
Please I'm a New user, I want to know if any one can help me to create rules so as to redirect trafic http to specific pool member and ftp trafic to another pool member.
thanks for all ...
Apr 16, 2007
The easiest way is to create two virtual servers, both with the same address, one listening on port 80 (for HTTP) and another on port 21 (for ftp). Then just assign the two virtuals their own default pool of servers. No iRules involved at all.
If you need to use a wildcard virtual (listening on all ports), then you are going to have to do a TCP::collect to get the payload content and inspect it to determine which protocol it's using. Search the forums for TCP::collect and I'm sure you'll find several examples of using it. Once you have determined which protocol you are receiving, you can use the "node" command to send that connection to the specfied backend server.
Here's some pseudo code for the node command.
...
if { traffic is determined to be HTTP } {
node 10.10.10.10 80
} elseif { traffic is determined to be FTP } {
node 10.10.10.20 21
}
...
-Joe
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