Registration

Dear SAP Community Member,
In order to fully benefit from what the SAP Community has to offer, please register at:
http://scn.sap.com
Thank you,
The SAP Community team.
Skip to end of metadata
Go to start of metadata

After investing a huge amount on a detailed sizing and the procurement of hardware the next very important thing is to utilize the most of it, an essential aspect of it that needs to be planned in an environment is load balancing. There are two aspects of a load balancing;

  • Distribution of the load across servers
  • High availability of the Application servers   

It becomes more challenging when it comes to http load balancing as the traditional method of message server load balancing does not work great for http requests. SAP has it’s own component (Web Dispatcher) to balance http load. In my recent implementation I had to design a landscape with a) Portal b) CRM c) ECC and d) Other Netweaver components. Portal was the single platform for the end users.

There are two strategies for load balancing via Web dispatcher;

Dynamic Weighted Round Robin: In this approach the load balancer determines the server selection via the load factor. As the request is routed to any server the load factor of the server changes and the next request is routed to the server that is determined by the load factor. This is the default settings of the web dispatcher and in this process the Web dispatcher decides the server selection.

The parameter to be set to activate this is;

wdisp/load_balancing_strategy = weighted_round_robin

Simple Weighted Round Robin: This approach route the load based on the capacity of the server. The webdispatcher maintains a capacity for each server that depends on the no. of dialog workprocesses available in the server. A server with a capacity of 10 would receive 10 consecutive requests before it is dispatched to the next server.

The request pattern isXXX….XYYY…YXXX….X

To activate this strategy the parameter

wdisp/load_balancing_strategy = simple_weighted_round_robin must be set.

Though the preferred method of load balancing would be a more dynamic in nature so that the server selection can be done at runtime, however with CRM and Web dispatcher the best way to load balance is by Simple Weighted Round Robin using a static server info file. This file contains the server information and the capacity for each server. With the Dynamic Weighted Round Robin method the webdispatcher constantly queries the message server to fetches the load information of each application server. With a high user load the determination of the application server is does not work as expected. Hence a better way is to maintain a static server info file which has the capacity information in it and the request can be routed based on that. The requests are not distributed evenly and have a high amount of deviation around 50% - 60% this causes significant load to specific application servers with the Dynamic Weighted Round Robin and no server info file present.

To configure the webdispatcher with the simple weighted round robin with the static server info file the following steps has to be performed:

  • Check the message server info first with the following url: http://
  • Set the parameters wdisp/load_balancing_strategy = simple_weighted_round_robin and wdisp/server_info_location = file:///usr/sap/<SID>/SYS/profile/serverinfo.icr
  • Create a serverinfo file and place it in a location; a sample of server info file is shown. The information shown in point 1 will help to create a server info file
  • For better performance enable caching in the webdispatcher by setting
    icm/HTTP/server_cache_0 = PREFIX=/,CACHEDIR=/usr/sap/<SID>/<Instance Nr.>/data/cache
  • Restart the SAP Webdispatcher

It might look as a less flexible process of load balancing but from CRM 2007 onwards the CRM system is generally accessed via the CRM-UI which is usually http(s) request. As the CRM system is an online system hence the load in the system is generally users. This approach will allow to evenly

  • No labels

1 Comment

  1. Former Member

    good overview of load balancing topic