Forum Discussion
Samir
Jan 26, 2020MVP
Hosting multiple websites on the same virtual server and load balancing requests to the appropriate webserver based on the host name requested. This can be achieved via iRule or F5 policy also.
** Make sure IP address bind with multiple DNS CNAME.
* Create the LB Pool based on the application requirement.
Pool_A[ 1perf.cloud123.com, 3perf.cloud123.com]
Pool_B [ 2perf.cloud123.com, 4perf.cloud123.com]
* Create iRule
when HTTP_REQUEST {
set host [string tolower [HTTP::host]]
switch -glob $host {
"www.xyz.com" {
pool pool_A
}
"www.pqr.com" {
pool pool_B
}
default { reject }
}
}
* Create the Virtual Server and assign irule.
Hope it will solve issue.