Thursday, July 9, 2009

SharePoint Load Balancing with F5 BIG-IP LTM

NOTE: Since originally posting, I realized you may want to do this by binding to individual ports in IIS instead of individual IPs (saves the need for all of those extra IPs and steps to add and configure as presented below, i.e. the members can be any port but the VIP would still be port 80)

In the MOSS 2007 deployments a co-worker and I designed for my company, the F5 BIG-IP Local Traffic Manager is the network device used to load balance Web Applications.  In the F5 configuration (sample below), each client facing MOSS Web Application requires a VIP (Virtual IP Address).  The VIP has several host (AKA member) server IP addresses associated to it to make up a Virtual Server Pool.  The VIP is what we associate to the end-user URL in DNS.

In sample, you see the MOSS Web Front Ends (WFE) listed as Hosts.  One WFE host can be included as a member in many Virtual Server Pools; however, one WFE host IP address cannot be a member of more than one Virtual Server Pool (Huh?..You may need to re-read that last sentence a few times – graphic at bottom of post should help).

So for the WFE hosts, get as many IP addresses as there are MOSS Web Applications (consider getting even more in case the need to add or extend web apps in the future arises…it will).  The IPs are added to the Network Adapter on each WFE (steps with screenshots here).  Once the IPs are added to the Network Adapter, they become available in IIS so a unique IP can be assigned to each IIS Website (Note:  While you’re in the IIS website properties, remove the host header from IIS website that was created when you first added the web app, otherwise, you’ll never be able to reach host header site collections created in this web app by adding a DNS alias to the VIP – don’t worry about this if you’re going with managed path based sites…I’ve said too much already…moving on).  As an example, in the figure below, there are 4 client facing web applications (Portal 1, Portal 2, Team Sites, and My Sites) and each of the 5 WFE Hosts has 4 unique IP addresses.

Further, the design takes load weights into consideration.  For high availability, the deployments consist of multiple WFEs.  With the multiple WFEs, you can distribute the load to maximize performance and availability.  MOSS installs all web applications and their corresponding application pool on every WFE host within the farm. However, to maximize CPU, not every application pool runs on every host (requires configuration of application pools performance settings – Joel Oleson has guidance here – If you’re dealing with load weights using multiple front ends and web apps, this can get complex -- I’ll post my PowerShell script for configuring IIS on multiple servers with multiple websites by reading in settings from a CSV file in a future post).

Using load weights, traffic load is distributed only on a select number of hosts allowing hosts to concentrate processes on a few application pools instead of all application pools.  The design leaves us with spare IPs.  This provides flexibility to add or remove WFEs to the Virtual Server Pools as needed.

 

lb

For more information about load balancing and F5, the F5 folks have a SharePoint deployment guide here.  The also have a nice Load Balancing 101 paper here.

No comments:

Post a Comment