how to balance the load between two Web-Servers using CCS 11501

Answered Question
Jul 3rd, 2010
User Badges:

Dear All,


           Can anyone tell me to balance the load in CSS 11503.My client's having two Web-servers which IP address 10.20.7.53(server1) and 10.20.7.53(Server2).Now i have configured  Load-balancing to balance the load within this two servers.So i configured one VIP(10.20.7.62) in the CSS 11503 to share the load.But whenever client wants to access the application using 10.20.7.62:7001/cm .then they are not able to connect.When they are giving 10.20.7.53:7001/cm and 10.20.7.54:7001/cm  in different Server's IP,then they able to connect the server and application.The two Web-servers are running Web-logic.


Can anyone tell me when clients request for the application using VIP,are they able get the application.From my point of view,I already configured owner,Service and content rules for load balancing.


Please find the attached configuration file for your convenience.


Thanks and regards...


Erfan

Correct Answer by Glenn R about 6 years 8 months ago

Giles is correct with what he said. Thank you.


What you have to configure now is a keep alive for the port your service is using


service Web-server-1
  ip address 10.20.7.53
  protocol tcp
  port 7001
  keepalive type tcp
  active


service Web-server-2
  ip address 10.20.7.54
  protocol tcp
  port 7001
  keepalive type tcp
  active


But  remember like giles said a page might still need to be refreshed from a client side to change the connection to the new server. Unless you are using so javascript push technology like Comet to force a page change from the server. But that is outsie the scope of this thread and would have to be done by your web application developers.

Correct Answer by Glenn R about 6 years 8 months ago

Firstly try using http://10.20.7.62:7001/cm/


Now lets strip your config back to basics and remove the following from the web-server-L5 content rule


# content Web-server-L5
#    no url "//10.20.7.62:7001/cm/*"

#    no dns bblcarma.bd.bracbank.com

#   balance srcip


Round-robin load balancing is the default and is not what I want you to use for this test as the web application could be breaking as a result of different traffic been send to different servers rather that all been processes by one server per user.



Now from the two server rules add the tcp protocol and port 7001


# service Web-server-1

#   protocol tcp

#   port 7001



# service Web-server-2

#   protocol tcp

#   port 7001


Lastly what is the error message you are getting when trying to load the web page ?




Add these changes to you config and then send me the new config.


G

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (2 ratings)
Loading.
Pablo Sun, 07/04/2010 - 10:21
User Badges:
  • Cisco Employee,

Hi Erfan


The problem is that your web server is running on port 7001 but that was not defined on your configuration with your current configuration all the traffic destined to the VIP will be forwarded to your backend servers in port 80 as well and that's why you never get a response.


Please configure the port under the services so the CSS can do the port translation from 80 to 7001

service Web-server-1
ip address 10.20.7.53
keepalive type http
port 7001
active 


service Web-server-2
ip address 10.20.7.54
keepalive type http
port 7001
active


Besides this change I see that you have a one-arm configuration which most likely will require a source group to avoid asymmetrical routing


# css(config)# group Web

# css(config-group[servers])# vip address 10.20.7.62

# css(config-group[Servers])# add destination service Web-server-1

# css(config-group[Servers])# add destination service Web-server-2

# css(config-group[Servers])# active


You can find further information about LB on one arm on this link.


http://www.cisco.com/en/US/partner/products/hw/contnetw/ps789/products_configuration_example09186a0080093dff.shtml


HTH

__ __

Pablo

eahmed007 Mon, 07/05/2010 - 03:37
User Badges:

Hi Palbo,


           Thanks for your help.I have configured CSS 11501 as you said in your reply.but now i am facing some problem Like whenever i am trying to access the Webserver using http:\\10.20.7.62:7001\cm\.its taking time to download the Web-page and some error showing in some pages.But when access using http:\\10.20.7.53:7001\cm\ or http:\\10.20.7.54:7001\cm\

the Webpage is coming very quick and its is working fine.Can you tell me why its happaning like that.Please assist me.



           Now I am able to get the application using http:\\10.20.7.62:7001\cm\ which is virtual IP for CSS 11503.In the Web-Server which is running using Web logic, there is an option for Listening IP address. So I have given ip address of individual IP address (like 10.20.7.53 in Server1 and 10.20.7.54 in Server2).


In the CSS 11503,I have created Service, Owner and Content rules. In the Content rules i have applied load balance method round robin method which is default for CSS 11503.But CSS 11503 forwarding the request to 10.20.7.53 not 10.20.7.54.But whenever I am giving show service summary or show summary command, then it showing hits in both servers.



Looking forward to your quick response



Thanks and regards..


Erfan





eahmed007 Tue, 07/13/2010 - 01:23
User Badges:

Hi,


       Can you help me on my previous query.I am facing problem.It would be highly appreciated if you help me on this issue.




Thanks and regards..


Erfan

Glenn R Thu, 07/15/2010 - 03:48
User Badges:

As a test try adding a stick-load-balance from source ip address


# owner bracbank

# content Web-servers

# balance srcip -> add this


Also what OS are the servers and what is their gateway.

eahmed007 Thu, 07/15/2010 - 09:36
User Badges:

Hi,


  Thanks for your reply.The Web servers are running Web-logic on Windows platform and gateway of these servers are router gateway.Please check the attached running configuration file for your convenience.Whenever i am trying to access the webpage using VIP address,then its not coming full Webpage and showing some error.But Whenever i am trying to access using Web-server IP address then its coming without any interruption.Please assist me whether i need to configure anything elase or not.I am eagerly waiting for your reply.



Thanks and regards...


Erfan

Glenn R Thu, 07/15/2010 - 10:46
User Badges:

Have you tried with adding the balance by src ip address as a test see my post above

eahmed007 Thu, 07/15/2010 - 22:01
User Badges:

Hi,


      I will try to add this balance method (balance scrip) and check whether its working or not.Can you tell me,Is there anything else i need to configure according to my  configuration file .Please check my configuration file if possible.I am  facing problem to solve this and looking for your valuable comments.Please assist me.




Thanks and regards..


Erfan

Glenn R Fri, 07/16/2010 - 06:56
User Badges:

To be honest your configuration looks fine for a basic two serever blancing setup.

Glenn R Fri, 07/16/2010 - 06:58
User Badges:

Another option would be to use Advanced load balancing. If your portal application requires that all requests be handled  by the same server, you must enable advanced load balancing for the content  rule. The arrowpoint-cookie method enables the content rule to associate the client to a  server based on the unique service identifier of the selected server.  Use the string command to add a service identifier for each service. Then add the advance-balance command with the arrowpoint-cookie option to the content rule definition.  In Listing 3, the bold text enables advanced load balancing.

eahmed007 Sat, 07/17/2010 - 22:11
User Badges:

Hi ,


         Thanks for your reply.My main problem is that i am not able to get the Web-page using http:\\10.20.7.62:7001\cm\.Its showing some error.I add default load balancer(Round-robin method).As per your suggestion,I add balance srcip method for caching.It would be highly appreciated if you can give me some suggestion for this problem according to my configuration file and Looking for your valuable reply.




Thanks and regards..


Erfan

Correct Answer
Glenn R Sun, 07/18/2010 - 10:49
User Badges:

Firstly try using http://10.20.7.62:7001/cm/


Now lets strip your config back to basics and remove the following from the web-server-L5 content rule


# content Web-server-L5
#    no url "//10.20.7.62:7001/cm/*"

#    no dns bblcarma.bd.bracbank.com

#   balance srcip


Round-robin load balancing is the default and is not what I want you to use for this test as the web application could be breaking as a result of different traffic been send to different servers rather that all been processes by one server per user.



Now from the two server rules add the tcp protocol and port 7001


# service Web-server-1

#   protocol tcp

#   port 7001



# service Web-server-2

#   protocol tcp

#   port 7001


Lastly what is the error message you are getting when trying to load the web page ?




Add these changes to you config and then send me the new config.


G

eahmed007 Sun, 07/18/2010 - 21:33
User Badges:

Hi ,


          Thanks for your update and suggestion.I will add those configuration line and let you know accordingly.But i have some query that if i don't mention url "//10.20.7.62:7001/cm/*" in the content rules then Web-page will be loading or not.



Its been nice to work with you and looking for your valuable comments.


Thanks and regards..



Erfan

eahmed007 Sun, 07/18/2010 - 23:03
User Badges:

Hi,


     Many many thanks to you.its been great to get your support.Now whole web-page is coming without any interruption.now they want to acces using  name like  bblcarma.bd.bracbank.com instead of  http://10.20.7.62:7001/cm/.So for this requirement what i need to configure to resolve the IP.So need your assistance and comments and how the load would be balanced.they want  50% load to one web-server and 50% load to another web-server.So i am bit confused to solve the problem.



I am looking forward to your valuable comments.Please help..!!!!




Thanks and regards...


Erfan

Glenn R Mon, 07/19/2010 - 01:47
User Badges:

You will not have to add the dns into the load balancer config but rather to your DNS servers to point to the VIP. The webserver must be setup to understand what the DNS name is for example using a Virtual host in Apache with the name resolution to that virtual host


Both server must use teh same DNS host in the web configuration.


How the balancing will work now is to round-robin new connections but keep users on the server they connect to. It sounds like the application you are using have session information and that coudl be what would be serving error in the page load. The way you have it configure now will do 50%-50% load balancing but like I said just keep each client on 1 server.


Is this to be firewalled in any way ?


Glenn

eahmed007 Mon, 07/19/2010 - 05:13
User Badges:

Hi,


      Thanks for your update and help.I didn't get your point that you said for each client for one server.ok i will do as you said for DNS server and let you know.Now i am facing one more problem,if i down any one of Web server , the web-page is not coming using  http://10.20.7.62:7001/cm/  .But we have to consider this situation also.If any one server get down we have to access Web-server using http://10.20.7.62:7001/cm/. Can you tell me why its happening like that.I am sending you the lattest configuration file for your convenicence.Please check.thanks for your help and assistance.In the configuration i add Group.Is it required ??  In the Web-server there is no firewall.




I am keenly waiting for your reply.......



Thanks and regards...


Erfan

  

Attachment: 
eahmed007 Mon, 07/19/2010 - 22:25
User Badges:

Hi,


       I am eagerly waiting for your reply.Its been great to get help from you.Please assist as per my previous mail if possible.



Thanks and regards...


Erfan

Gilles Dufour Tue, 07/20/2010 - 05:49
User Badges:
  • Cisco Employee,

maybe you could reward the person who assisted you by rating his response.


Regarding your new issue, does the CSS detect the server is down ?

You are using the default icmp probe, so if the application is down, but the server is still up, the CSS will consider the application is still alive.

You may have to configure an http probe or a tcp probe.


Also, if a server goes down and you have a connection open with that server, when this server goes down, the CSS will not automatically reassign the connection to the other server.

You need to refresh the page in your browser so that a new connection is established and sent to the active server.


Gilles.

eahmed007 Wed, 07/21/2010 - 01:42
User Badges:

Hi,


         Thanks for your update.you are right.If i get down the service of one of the servers,then application is not coming But i have to consider this situation.So can you tell me how can i configure CSS to solve this problem.I am really greatful to you guys for your help and support and looking forward to your reply.Definitely  I would rate this response.


Can you tell me how to configure an http probe or a tcp probe to solve the problem in CSS.




Thanks and regards..


Erfan

Correct Answer
Glenn R Wed, 07/21/2010 - 01:53
User Badges:

Giles is correct with what he said. Thank you.


What you have to configure now is a keep alive for the port your service is using


service Web-server-1
  ip address 10.20.7.53
  protocol tcp
  port 7001
  keepalive type tcp
  active


service Web-server-2
  ip address 10.20.7.54
  protocol tcp
  port 7001
  keepalive type tcp
  active


But  remember like giles said a page might still need to be refreshed from a client side to change the connection to the new server. Unless you are using so javascript push technology like Comet to force a page change from the server. But that is outsie the scope of this thread and would have to be done by your web application developers.

eahmed007 Wed, 07/21/2010 - 03:19
User Badges:

Hi,


        Thanks for your reply and i will let you know the update after adding keep alive type tcp.



Thanks again for your help



Thanks and regards...


Erfan

eahmed007 Wed, 07/21/2010 - 21:05
User Badges:

Hi,


     Thanks for your help.Everything is working fine.Its been nice to work with you .Hope  that i will get help from you guys in near future also.




Thanks and regards...


Erfan

eahmed007 Thu, 09/02/2010 - 02:55
User Badges:

Hi Glenn,


                 Hope you are doing fine.Now i am facing a problem in CCS 11501.I have configured the load Balancer as per your advice and it was working fine.Now its having problem we client wants to login one of the two servers using virtual IP address of load Balancer,First it login one server after sometime its redirect the session to other server.So its creating a problem to save the content and input data.When client again login to one of the server ,He doesn't get any data which he saved before.Need your assistance  on this issue.



Should i have to do anyting else to overcome this problem.I am sending the configuration file for your convenience.



It would be highly appreciated if you response and eagerly waiting for your reply.



Thanks and regards..


Erfan

Glenn R Fri, 09/03/2010 - 08:47
User Badges:

Erfan,


Suspend the group setting and test again.


# group servers

# suspent

# exit

# wr mem


I have not used group before but will have a quick read and let you know.


What IP Adresses are the clients comming from ?

eahmed007 Sat, 09/04/2010 - 20:41
User Badges:

Hi Glenn,


           Thanks for your reply.Can you tell me that is it happening for Group servers or some other reason.For you information,client is using different network.If you need any other information,please let me know.


Main problem is that after some time client's session is redirecting to another server which i mentioned in my previous mail.Please help me to solve the problem.I am eagerly waiting for your reply.




Thanks and regards..


Erfan

eahmed007 Sun, 09/05/2010 - 19:48
User Badges:

Hi Glenn,


              Hope you are doing fine.I am eagerly looking forward to your valuable comments and need your assistance on my previous response.



Please help me to resolve the problem.



Thanks and regards...


Erfan

Glenn R Tue, 09/07/2010 - 11:20
User Badges:

What happens when you remove the group and associated configuration ?

eahmed007 Tue, 09/14/2010 - 00:23
User Badges:

Hi Glenn,


                Sorry for late reply.I will let you know the update soon after removing the Group and associated configuration.


Thanks for your help and reply.



Thanks and regards..


Erfan

Actions

This Discussion