Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We are trying to find the most suitable load balancing solution that will work with our application, but I quickly found I don't know much on the subject. We were going to run Varnish Cache but we use client IP addresses at various levels and SSL - starting to get complicated... please help

Here's situation, we have one machine serving the below and looking spanning this across three. Probably share the one database.

Three types of traffic:

  1. Images for emails - Basic Apache traffic (minimal)
  2. Flash application - Large download(s) once per client
  3. SOAP Webservice - Up to a POST per client per second

The stack:

  1. Linux with PSAD
  2. Apache with Mod_Security
  3. Tomcat (Apache worker), JAX-WS app and MySQL database

Complications:

  1. Maxmind GeoIP at app - needs client's IP address
  2. mod_security on Apache - also wants IP address
  3. SSL for both the Flash app and all SOAP calls

This is a preemptive measure for the client so we don't have load problems to solve as such, except if we test a DOS attack :)

Would Pound or Crossroads work? Is a software load balancer the right solution?

share|improve this question
    
Looks like request.getHeader("X-Forwarded-For") should fix my client IP address at the app level –  KCD Jul 20 '11 at 1:43
    
I think I can also get mod_security working with mod_rpaf or mod_extract_forwarded2 ... still working on it! –  KCD Jul 20 '11 at 2:08

1 Answer 1

up vote 0 down vote accepted

You want an L3 load-balancer -- something that forwards the TCP traffic to a backend server without doing anything in the middle. Anything that proxies or otherwise intercepts your TCP connections and forwards them on is not going to work (or will involve significant configuration and fragility). I use and recommend the Linux Virtual Server for all your load-balancing needs.

share|improve this answer
    
Thanks @womble, I think that is a good solution. Actually we have a DNS round-robin which is simple for now. We don't have sessions and are ok with minor unbalances and doing maintenance out of hours. In future will talk to our hosting provider about LVS. –  KCD Jul 22 '11 at 3:44

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.