views:

11

answers:

1

Hi,

I'm working on mobile web application targeted toward Webkit-based browsers on devices such as iPhone, Android, etc. I've noticed that when and iPhone switches from Edge to 3g or vice-versa a new IP address is assigned to the device, which makes sense.

The problem is that I'm connecting to a web application sitting on two Windows Server 2003 servers load balanced by Microsoft's Network Load Balancing Services. The web app makes an initial connection and is sent to one of the two servers. The load balancing software looks at the first three octets of the IP (Class C) and uses that for future requests to ensure that future requests are sent to the original server.

The problem is that when the mobile device switched from Edge to 3G (particularly an iPhone with AT&T as the provider) a new IP address is assigned to the device and most of the time the new IP addresses 3rd and 4th octets are different, thereby causing load balancing to be unable to determine which server to send the request to.

Has anyone else found this to be a problem when developing a mobile web application? If so, what was your solution?

Any ideas other than getting rid of load balancing and using a single server would be greatly appreciated.

Thanks, -Scott

A: 

Best case would be to not require clients to stay connected to the same server, but if your application is already designed with that restriction, it may be difficult to change now.

You may be able to instruct your load balancing software to set a cookie on each new incoming client and then assign the server based on that.

rpetrich