Amazon Elastic Load Balancer (ELB): how to ensure that clients are re-resolving DNS frequently

hi.

after a couple of weeks of load testing with Gatling (really awesome tool … thanks so much for making this available) we ran into an issue with the ELB.

we think the issue is as described here: “Best Practices in Evaluating Elastic Load Balancing” (http://aws.amazon.com/articles/1636185810492479)

DNS Resolution

If clients do not re-resolve the DNS at least once per minute, then the new resources Elastic Load Balancing adds to DNS will not be used by clients.

This can mean that clients continue to overwhelm a small portion of the allocated Elastic Load Balancing resources, while overall Elastic Load Balancing is not being heavily utilized.

This is not a problem that can occur in real-world scenarios, but it is a likely problem for load testing tools that do not offer the control needed to ensure that clients are re-resolving DNS frequently.

So we used jnettop on the Gatling server and saw that during the load test every 60 seconds or so the IP address changed to one of the available ip addresses provided by the ELB DNS entry.
But Gatling never used all of the available IP addresses during the load test.

Is there a way to use Gatling for load testing and application “behind” Amazon’s ELB?

Thanks a bunch.
Michael

Hi,

Have you tried playing with the DNS lookup cache, like adding -Dsun.net.inetaddr.ttl=0 to the command line?
http://docs.oracle.com/javase/7/docs/technotes/guides/net/properties.html

Cheers,

Stéphane

Hi,

-Dsun.net.inetaddr.ttl=0

did the trick. Awesome.

Thanks again.
Michael

Great!
I think that’s something we’d better add to the FAQ.

Hi Stéphane -

Reading the FAQ (http://gatling.io/docs/2.0.0-RC6/project/faq.html), let’s say that I have:

** route53 DNS CNAME **

a.b.c → ELB’s Public DNS

After reading the FAQ link (http://aws.amazon.com/articles/1636185810492479), let’s say that, after unning a ~1 hour load test w/ gatling that triggers scaling events, 2 EC2 boxes grow to 10.

Is it still necessary for me to set the System Property (-Dsun.net.inetaddr.ttl=0)?

It’s not clear to me whether gatling, without that flag, will cache the DNS resolution to the public DNS or an ec2 instance.

In short, if I’m using a route53 entry, is it still necessary for me to specify the flag iff the public DNS is cached?