Forum Discussion
rodrigo_Benzaqu
Nimbostratus
Jun 01, 2005what I have wrong in this rule
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/fd/" }
{
use pool FD_SERVERS
} elseif
{
use pool Mexico
}
}
01070151:3: Rule [FD_MLA] error:
line 2: [missing a script after "if"] [ ]
line 3: [undefined procedure:
use pool FD_SERVERS
] [{
use pool FD_SERVERS
} elseif
{
use pool MLA
}]
Thanks guys
6 Replies
- JRahm
Admin
Replace the elseif with else, or supply another condition with the elseif statement. - rodrigo_Benzaqu
Nimbostratus
Ok, now look a this.
when HTTP_REQUEST {
if { [HTTP::uri] starts_with "/fd/" }
{
use pool FD_SERVERS
}
}
01070151:3: Rule [FD_RESTO] error:
line 2: [missing a script after "if"] [ ]
line 3: [undefined procedure:
use pool FD_SERVERS
] [{
use pool FD_SERVERS
} ] - You need to have the opening curly brace on the same line as the if statement.
when HTTP_REQUEST { if { [HTTP::uri] starts_with "/fd/" } { use pool FD_SERVERS } } - rodrigo_Benzaqu
Nimbostratus
Thanks Joe.
If I want to add this rule to my virtual server, when I do it I receive :
01070394:3: HTTP_REQUEST event in rule (FD_FETCH) requires an associated HTTP or FASTHTTP profile on the virtual server (resto).
The virtual server "resto" is for http. What do I miss ?
Thanks in advance
Rodrigo - Your Virtual Server must have an associated HTTP profile assigned to it to be able to receive the HTTP_REQUEST event. Look on the configuration page for your Virtual Server and you'll see a dropdown list with the title "HTTP Profile". You can either select the default "http" base profile or one that you've created that is derived from http.
You can also receive this event if your Virtual Server is of type "Performance (HTTP)" and you have a Protocol Profile derived from "fasthttp" assigned to it.
-Joe - rodrigo_Benzaqu
Nimbostratus
Hey, you are the man!!
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