-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Jon,

Just my 2 cents - but I think Joshua has it right. If you're using session management and weighted load balancing, then you must pass the requests through your proxy - and hence your advantage of geolocation is gone. If you're already using an external redirect, then the proxy balancer has no way of knowing how many concurrent connections worker is maintaining or how long they take or how much bytes they serve (this would be needed for balancing purposes).

The only way I see it is to let mod_rewrite warp the browser to an external url, e.g. from www.mysite.org to other domain names (www.us.mysite.org, www.eu.mysite.org etc.) and then loose all contact with the browser - which would mean to forget about sessions and balancing.

Incidentally, if you have a good DNS provider or if you handle your own DNS, then you could find a solution there - resolve www.mysite.org depending on the requestor IP to a US-address, a EU- address, and so on. An alternative approach, but I'm pretty sure that this can work.

Hope this helps,
Karel

On Jun 18, 2007, at 10:53 PM, Jon Keys wrote:

Hey Joshua,

You're right except we don't use mod_proxy_balancer in conjunction with mod_proxy ... we use mod_rewrite with '[R]' directive and point to the mod_proxy_balancer worker to determine which server to externally redirect to. Does this make sense?

The reason we chose to do this was to take advantage of some of the nice features in mod_proxy_balancer (like session management, weighted load balancing, etc...). We are, however, not locked in to this solution. If something more efficient / easier to manage is out there we are definitely open to suggestions.

Thanks for your reply,

Jon

> Date: Mon, 18 Jun 2007 16:10:50 -0400
> From: [EMAIL PROTECTED]
> To: users@httpd.apache.org
> Subject: Re: [EMAIL PROTECTED] Geolocation Question
>
> On 6/18/07, Jon Keys <[EMAIL PROTECTED]> wrote:
> >
> > Hi,
> >
> > I'm setting up some load balancing based on Apache with mod_proxy_balancer > > and I'd like to incorporate geolocation based on IP address into the load
> > balancing algorithm.
> >
> > I know that IP's are not a reliable way of determining location, but we > > purchased a package from ip2location to try and be as accurate as possible. > > Even still, it's not perfect and that's OK because we are just distributing > > the load of some free downloads ... if someone gets redirected to a server
> > that's not that close to them it won't be the end of the world.
> >
> > Anyway, does anyone know of such a patch / mod / plugin / application > > compatible with apache2? If not, some pointers on where to begin developing
> > this would be greatly appreciated.
>
> Maybe I'm missing something, but this doesn't make any sense to me.
>
> If you are using mod_proxy_balancer, then all requests will go through > the apache proxy server. That means there is no benefit in putting the
> back-end server close to the client. In fact, you want the back-end
> server close to the balancer.
>
> If you want the client to access stuff from a closer server, you
> should issue an external redirect. mod_rewrite would be a standard way
> to access a database to do a conditional redirect.
>
> Joshua.



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (Darwin)

iD8DBQFGdvpu23FrzRzybNURAoIlAJ0W8jkgGpIg+lHgBxtqnX4G5+tvCwCfTbaL
KjAoCjJib8KdbsYJtqMS2yc=
=FJKx
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to