I think with your iRule, you'll wind up in an endless loop for mobile clients unless you add a URI check for the redirect page. And I'm assuming that if the user agent isn't for a mobile client, you want to redirect them to the page you mentioned... Maybe something like this would work
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] contains "www.mobilesite.com"}{
switch -glob [string tolower [HTTP::header User-Agent]] {
"*ipad*" -
"*iphone*" -
"*android*" -
"*windows phone*" -
"*windows ce*" -
"*bada*" -
"*bb10*" -
"*blackberry*" -
"*symbinos*" -
"*symbain os*" -
"*symbian*" -
"*java*" -
"*winowsphone*" -
"*windowsce*" {
if {not ([string tolower [HTTP::uri]] equals "/slm/faces/m/index.jspx")} {
HTTP::redirect "www.mobilesite.com/slm/faces/m/index.jspx"
return
}
}
default {
HTTP::redirect "https://mysite.com/OLA/faces/siteLocator.jspx"
}
}
}
}