Jack_Huang_5191
Jul 15, 2005Nimbostratus
When v4.5.10 irule code migrate to v9.1, it can't work.
I have a right v4.5.10 irule script. It works well in the big-ip 4.5.10. The function of this script is to traffic http uri contains .sdp, 3gp, mov, mp4 to a pool, sun_stream_servers. Other http uri traffics to real_stream_servers. The 4.5.10 script is as follows:
if ( http_uri matches_regex ".sdp" ) {
use (Sun_Stream_Servers)
}
else if ( http_uri matches_regex ".3gp" ) {
use (Sun_Stream_Servers)
}
else if ( http_uri matches_regex ".mov" ) {
use (Sun_Stream_Servers)
}
else if ( http_uri matches_regex ".mp4" ) {
use (Sun_Stream_Servers)
}
else {
use (Real_Stream_Servers)
}
Now, I have migrated it to v9.1. I found it can't work well. I use the default http profile. The new 9.1 script is as follows:
when HTTP_REQUEST {
if { [HTTP::uri] matches_regex ".sdp" } {
pool Sun_Stream_Servers
} elseif { [HTTP::uri] matches_regex ".3gp" } {
pool Sun_Stream_Servers
} elseif { [HTTP::uri] matches_regex ".mov" } {
pool Sun_Stream_Servers
} elseif { [HTTP::uri] matches_regex ".mp4" } {
pool Sun_Stream_Servers
} else {
pool Real_Stream_Servers
}
}