Measuring DNS Server performance with JMeter

2,112 views
Skip to first unread message

APC

unread,
Mar 24, 2011, 8:26:16 AM3/24/11
to jmeter-plugins
Yep, I'm doing it right now.
It WORKS! It is possible!

Maybe I need to write an article on making such tests...

Karthik B V M

unread,
May 18, 2011, 4:20:54 AM5/18/11
to jmeter-plugins
Yes please. I would like to read the article.

Thanks
Karthik

Andrey Pohilko

unread,
May 18, 2011, 6:32:58 AM5/18/11
to jmeter-...@googlegroups.com
Ok, I'm writing it. Soon I'll publish it and give you a notice.

Andrey Pohilko

unread,
May 19, 2011, 12:48:25 PM5/19/11
to jmeter-...@googlegroups.com

Adrian Speteanu

unread,
May 20, 2011, 10:46:39 AM5/20/11
to jmeter-...@googlegroups.com
Nice work, good article.

Sometimes when you can't ensure a stable throughput with jmeter, it can also be from client side configs as well, JVM especially - I run into this often when trying to run jmeter in GUI just to be able to monitor the graphs from the plugin.

On 19 May 2011 19:48, Andrey Pohilko <a...@apc.kg> wrote:
Done: http://apc.kg/read/jmeter_dns/

Karthik B V M

unread,
May 23, 2011, 6:11:14 AM5/23/11
to jmeter-plugins
Nice article.Thank you very much.
I also tried the new Perfmon metrics collector on one of my web test.
works fine with distributed test setup (one master one slave).

Andrey Pohilko

unread,
May 23, 2011, 6:31:26 AM5/23/11
to jmeter-...@googlegroups.com
Good news! 

I expected better distributed mode work and cmd tool support from new perfmon collector

pin2...@gmail.com

unread,
Jun 24, 2011, 1:03:34 PM6/24/11
to jmeter-...@googlegroups.com
Hi Andrey...it is a very nice article.
I am trying to open the test plan in Jmeter 2.4 but it is displaying a error message in the log file as - jmeter.save.SaveService: Conversion error com.thoughtworks.xstream.converters.ConversionException: kg.apc.jmeter.perfmon.PerfMonCollector : kg.apc.jmeter.perfmon.PerfMonCollector : kg.apc.jmeter.perfmon.PerfMonCollector : kg.apc.jmeter.perfmon.PerfMonCollector
 
Could you guide me, what is the cause of this error?

Andrey Pohilko

unread,
Jun 24, 2011, 4:26:38 PM6/24/11
to jmeter-...@googlegroups.com
That's because I used not yet released PerfMon Metrics Collector. It is available in latest developer build (see deprecated downloads).

worldadvert...@gmail.com

unread,
Jul 26, 2014, 10:05:31 AM7/26/14
to jmeter-...@googlegroups.com
Hi Andrey,

I am using your method described but I am getting error.  I have a list of DNS in csv file with only one column of web addresses and I call it hostname.  Then I use UDP Request, and in the Data Encode/Decode class is "kg.apc.jmeter.samplers.DNSJavaDecoder", and in Request Data its "${hostname} A IN".  I am new to JMeter, can you help which part I am doing wrong?


On Friday, June 24, 2011 9:26:38 PM UTC+1, Andrey Pohilko wrote:

Andrey Pohilko

unread,
Jul 26, 2014, 12:40:49 PM7/26/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Hi,

Which error do you have? Pleasem be specific.

For now I can just guess that you missed first dot, or forgot to reverse address parts in ${hostname}. Please read examples with more attention to this detail.

--
Andrey

суббота, 26 июля 2014 г., 18:05:31 UTC+4 пользователь worldadvert...@gmail.com написал:

worldadvert...@gmail.com

unread,
Jul 27, 2014, 5:40:33 AM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Hi Andrey,

The error is:
2014/07/27 10:29:23 ERROR - kg.apc.jmeter.samplers.AbstractIPSampler: hostname java.nio.channels.UnresolvedAddressException
 at sun.nio.ch.Net.checkAddress(Net.java:127)
 at sun.nio.ch.DatagramChannelImpl.connect(DatagramChannelImpl.java:733)
 at kg.apc.io.DatagramChannelWithTimeouts.connect(DatagramChannelWithTimeouts.java:119)
 at kg.apc.jmeter.samplers.UDPSampler.getChannel(UDPSampler.java:63)
 at kg.apc.jmeter.samplers.UDPSampler.processIO(UDPSampler.java:85)
 at kg.apc.jmeter.samplers.AbstractIPSampler.sample(AbstractIPSampler.java:115)
 at org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:429)
 at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:257)
 at java.lang.Thread.run(Thread.java:744)

The .csv file I am using has one column of addresses eg. facebook.com, google.com, yahoo.com.  In CSV Data Set Config's Variable Names field I entered hostname. Under UDP Request:
Hostname/IP: hostname
UDP Port: 53
Data Encode/Decode class: kg.apc.jmeter.samplers.DNSJavaDecoder
Request Data: ${hostname} A IN

I couldn't figure out what error is that given above as it occurs on every line of address lookup from csv file.  Any idea?  Thanks in advance!

Andrey Pohilko

unread,
Jul 27, 2014, 6:10:34 AM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
This error is because Sampler cannot resolve the hostname you entered for the server address. It's not about the request contents. Check the server address you use.

--
Andrey

воскресенье, 27 июля 2014 г., 13:40:33 UTC+4 пользователь worldadvert...@gmail.com написал:

Andrey Pohilko

unread,
Jul 27, 2014, 6:11:50 AM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Also DNSJava expects reversed addresses that start with the dot. So you must have them as:
.com.facebook
etc

--
Andrey

воскресенье, 27 июля 2014 г., 13:40:33 UTC+4 пользователь worldadvert...@gmail.com написал:

worldadvert...@gmail.com

unread,
Jul 27, 2014, 10:55:49 AM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Hi Andrey,

I've changed the csv file manually to .com.google, .com.yahoo, etc. Jmeter managed to picked up these hostnames but still give this error:
ERROR - kg.apc.jmeter.samplers.AbstractIPSampler: .com.google java.nio.channels.UnresolvedAddressException

I've searched many and still could not figure out.  Did I miss something again?

Andrey Pohilko

unread,
Jul 27, 2014, 3:59:23 PM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Again, the problem not in csv. Problem is that JMeter fails to resolve addres in Hostname/IP field to connect to the server. Try using IP address instead of hostname in that fields.

--
Andrey

воскресенье, 27 июля 2014 г., 18:55:49 UTC+4 пользователь worldadvert...@gmail.com написал:
Message has been deleted

worldadvert...@gmail.com

unread,
Jul 27, 2014, 6:01:42 PM7/27/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Hi Andrey,

I tried with IP as well as other hostnames possibilities but all returned errors:
1)  java.lang.IllegalArgumentException: Invalid name '.8.8.8.8'
2)  org.xbill.DNS.RelativeNameException: '8.8.8.8' is not an absolute name
3)  java.nio.channels.UnresolvedAddressException    <---- this error from .com.google and .com.google.www
4)  org.xbill.DNS.RelativeNameException: 'google.com' is not an absolute name
5)  java.net.SocketTimeoutException: Timeout exceeded while reading from socket    <---- this error from google.com. (Timeout set at 10sec)

I know no.2, 4, and 5 are not valid trials but I'm just running out of ideas. Pls help.. thx.

Andrey Pohilko

unread,
Jul 28, 2014, 2:56:19 AM7/28/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Can you show a screenshot of your UDP Sampler ?

понедельник, 28 июля 2014 г., 2:01:42 UTC+4 пользователь worldadvert...@gmail.com написал:

worldadvert...@gmail.com

unread,
Jul 28, 2014, 4:58:50 AM7/28/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Here it is: 

worldadvert...@gmail.com

unread,
Jul 28, 2014, 8:22:34 AM7/28/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
By the way, I've changed the 'Hostname/IP' field below to "8.8.8.8" instead of "${hostname}" (I supposed this means the DNS server to be directed at), but it still gives the same errors:
Response message: org.xbill.DNS.RelativeNameException: 'com.google' is not an absolute name
Response message: java.lang.IllegalArgumentException: Invalid name '.com.google'
Response message: org.xbill.DNS.RelativeNameException: 'google.com' is not an absolute name

Andrey Pohilko

unread,
Jul 28, 2014, 9:24:52 AM7/28/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com
Right. The problem is that you used ${hostname} both for the DNS server and DNS request. Treat them different. Hostname/IP should contain the address of the server to be stressed. Preferrably IP address of it. 8.8.8.8 is working example, but you don't want to stress Google servers, do you?

And your Request Data field should contain changing variable from CSV. And that variable should be in a form of "google.com.", note the dot at the end. Sorry, I was misleading you about reverse DNS form in request.

Please try it.
--
Andrey

понедельник, 28 июля 2014 г., 16:22:34 UTC+4 пользователь worldadvert...@gmail.com написал:

worldadvert...@gmail.com

unread,
Jul 28, 2014, 10:40:36 AM7/28/14
to jmeter-...@googlegroups.com, worldadvert...@gmail.com

Hi Andrey, it works now with the dot at the end.  Thank you so much for your time to assist me.  Really appreciate it!

brian...@gmail.com

unread,
Jun 22, 2016, 3:18:34 AM6/22/16
to jmeter-plugins
Hi Andrey,

Is this still available?  I can't seem to get to the site?

Brian

On Thursday, May 19, 2011 at 6:48:25 PM UTC+2, Andrey Pokhilko wrote:
Done: http://apc.kg/read/jmeter_dns/

Andrey Pokhilko

unread,
Jun 22, 2016, 11:27:29 AM6/22/16
to jmeter-...@googlegroups.com
--
You received this message because you are subscribed to the Google Groups "jmeter-plugins" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-plugin...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

rlh...@gmail.com

unread,
Jul 27, 2016, 5:42:19 PM7/27/16
to jmeter-plugins
Is there an updated hot to for this?
Looks that the latest Jmeter is 3.0 and I can't find a UDP request object to add.

Andrey Pokhilko

unread,
Jul 28, 2016, 2:55:31 AM7/28/16
to jmeter-...@googlegroups.com
You need to install UDP plugin for that: https://jmeter-plugins.org/?search=udp

Andrey Pokhilko

rlh...@gmail.com

unread,
Aug 3, 2016, 3:43:53 PM8/3/16
to jmeter-plugins
Thanks.

Also with the HEX copied from wireshark does that make it a DNS request for just one address?  Would it be possible to have it use a list of addresses to query?

Andrey Pokhilko

unread,
Aug 4, 2016, 2:41:04 AM8/4/16
to jmeter-...@googlegroups.com

If you mean destination IP, then it should work with setting variable there.

If you mean source IP, there is feature request earlier in this forum to support source address change for the plugin.

Andrey Pokhilko

Richard Harris

unread,
Aug 16, 2016, 11:05:32 AM8/16/16
to jmeter-...@googlegroups.com
I mean the name that the DNS query is asking the server to resolve.

I'm thinking it'd be good to have a list of DNS names to be resolved.

I'd like to use this to benchmark and stress test a pair of windows DNS servers (maybe even all 5 that we use at work.) and figure instead of having it potentially query the servers for the same name repeatedly it would be nice to be able to feed it a list, maybe even as a csv file.

To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-plugins+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "jmeter-plugins" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jmeter-plugins/QfI0AcCeFF8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jmeter-plugins+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Physics is great

Andrey Pokhilko

unread,
Aug 16, 2016, 11:15:11 AM8/16/16
to jmeter-...@googlegroups.com

Then, just use variable of IP addresses in the field. That is much more reliable than dealing with DNS resolve...

Andrey Pokhilko

Richard Harris

unread,
Aug 16, 2016, 11:16:23 AM8/16/16
to jmeter-...@googlegroups.com
Well if you're stress testing a DNS server you'd want it to be resolving names in the test.

Andrey Pokhilko

unread,
Aug 16, 2016, 11:18:36 AM8/16/16
to jmeter-...@googlegroups.com

I'm all confused now :)

If you want to change DNS name in request - then again, use variable in it.

In this article: https://jmeter-plugins.org/wiki/dns_test_using_jmeter/ it is demonstrated how to read that list from CSV file.

Andrey Pokhilko

efu...@gmail.com

unread,
Aug 30, 2016, 11:39:27 PM8/30/16
to jmeter-plugins
In the article, the link to the final Test Plan is broken, pointing to a googlecode link.  Could you update it?  

On Thursday, March 24, 2011 at 6:26:16 AM UTC-6, Andrey Pokhilko wrote:
Yep, I'm doing it right now.
It WORKS! It is possible!

Maybe I need to write an article on making such tests...

Andrey Pokhilko

unread,
Aug 31, 2016, 4:12:01 AM8/31/16
to jmeter-...@googlegroups.com

Fixed

Andrey Pokhilko

--

rlh...@gmail.com

unread,
Feb 10, 2017, 12:58:28 PM2/10/17
to jmeter-plugins
So I've downloaded Jmeter 3.1, put the UDP plugin files in the right location, even added the plugin manager (and it displays that the UDP plugin is loaded.
Then when I open the "Final test plan" I get the attached error.
Jmeter-DNS-Error.png

Andrey Pokhilko

unread,
Feb 10, 2017, 1:06:52 PM2/10/17
to jmeter-...@googlegroups.com

This example JMX requires to have Throughput Shaping Timer and AutoStop plugins installed.

Andrey Pokhilko

Richard Harris

unread,
Feb 10, 2017, 1:11:25 PM2/10/17
to jmeter-...@googlegroups.com
I just installed both "Auto-Stop Listener" and Throughput Shaping Timer" (as named in the PlugIn Manager) via the plugin manager and get the attached error.
Inline image 1

To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-plugins+unsubscribe@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "jmeter-plugins" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jmeter-plugins/QfI0AcCeFF8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jmeter-plugins+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Physics is great

Andrey Pokhilko

unread,
Feb 10, 2017, 1:32:13 PM2/10/17
to jmeter-...@googlegroups.com

Unfortunately, that example JMX also involves many other plugins. Look - it asks for PerfMon on your screenshot.

Andrey Pokhilko

Richard Harris

unread,
Feb 10, 2017, 1:34:36 PM2/10/17
to jmeter-...@googlegroups.com
Any chance you might have a list of the required pligins?  I currently have the following loaded. (just now before taking the screenshot I loaded perfmon)
Inline image 1

Richard Harris

unread,
Feb 10, 2017, 2:20:55 PM2/10/17
to jmeter-...@googlegroups.com
So after loading the perfmon plugin I still get another error, a much less informative one.  Thus have to go to the log to get more meaningful information about it.

Inline image 1


Inline image 2

Also

Inline image 3
--
Physics is great

Kunal Khandelwal

unread,
Mar 1, 2017, 8:50:52 AM3/1/17
to jmeter-plugins
Hello Andrey,

I am Kunal, i am facing problem to configure the Jmeter in my windows PC, can you please help me 


thanks,
Kunal Khandelwal

qa.mov...@gmail.com

unread,
May 15, 2018, 2:49:13 AM5/15/18
to jmeter-plugins

artem....@blazemeter.com

unread,
May 15, 2018, 5:19:41 AM5/15/18
to jmeter-plugins
Hi Kunal

What problems do you have now? If you have problems with DNS possible these  articles can help you:
https://www.blazemeter.com/blog/dns-cache-manager-right-way-test-load-balanced-apps
https://jmeter-plugins.org/wiki/dns_test_using_jmeter/

Artem

среда, 1 марта 2017 г., 16:50:52 UTC+3 пользователь Kunal Khandelwal написал:

Auro

unread,
Jun 15, 2019, 3:31:39 AM6/15/19
to jmeter-plugins
HI Andrey, I tried to test my DNS and also google DNS following the article, but I'm always getting java.net.SocketTimeoutException: Timeout exceeded while reading from socket
I tried different settings: timeout 10s, dnsjava-3.0.0.jar,  dnsjava-2.1.9.jar. All with jmeter 5.1.

Do you know if this works with jmeter 5.1?

test.jpg

Auro

Do you know
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "jmeter-plugins" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jmeter-plugins/QfI0AcCeFF8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jmeter-...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Physics is great
--
You received this message because you are subscribed to the Google Groups "jmeter-plugins" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "jmeter-plugins" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jmeter-plugins/QfI0AcCeFF8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jmeter-...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Physics is great
--
You received this message because you are subscribed to the Google Groups "jmeter-plugins" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-...@googlegroups.com.

Andrey Pokhilko

unread,
Jun 16, 2019, 2:33:37 AM6/16/19
to jmeter-...@googlegroups.com

Hi,

I haven't tried it with 5.1.

Do you have network sniffer to confirm that DNS responses arrive? Are there any errors in JMeter.log?

--

Andrey Pokhilko

15.06.2019 10:31, Auro пишет:

Auro

unread,
Jun 16, 2019, 12:50:02 PM6/16/19
to jmeter-plugins

err.jpg

Hi Andrey,
it seems that I'm not able to connect to any DNS. On the jmeter log there is not any error. The timeout is reported on the response
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-...@googlegroups.com.

Andrey Pokhilko

unread,
Jun 17, 2019, 2:48:14 AM6/17/19
to jmeter-...@googlegroups.com

I have just tried with JMeter 5.1.1 and latest UDP plugin, no manual JAR copying (that article is so old).

It worked fine for me. Probably you have some issues either with networking, or with JMeter. Try with clean installation.

--

Andrey Pokhilko

16.06.2019 19:50, Auro пишет:

Auro

unread,
Jun 17, 2019, 4:41:28 AM6/17/19
to jmeter-plugins
Hi Andrey,
if I try via 4G network it works. If I try via LAN, home+vpn or office, it doesn't work. I suspect that the firewall is blocking the call.

thanks for your time.

Auro

Asha Singh

unread,
Jun 17, 2019, 4:42:47 PM6/17/19
to jmeter-plugins
Hi Andrey,

Please provide me also the copy of your article.

Thanks.

Andrey Pokhilko

unread,
Jun 18, 2019, 2:57:15 AM6/18/19
to jmeter-...@googlegroups.com

https://jmeter-plugins.org/wiki/dns_test_using_jmeter/


Andrey Pokhilko

17.06.2019 23:42, Asha Singh пишет:
**********************************************************************************************
Important Note
This email (including any attachments) contains information which is confidential and may be subject to legal privilege.  If you are not the intended recipient you must not use, distribute or copy this email.  If you have received this email in error please notify the
sender immediately and delete this email. Any views expressed in this email are not necessarily the views of IRESS Limited.

It is the duty of the recipient to virus scan and otherwise test the information provided before loading onto any computer system.
IRESS Limited does not warrant that the information is free of a virus or any other defect or error.
**********************************************************************************************
--
You received this message because you are subscribed to the Google Groups "jmeter-plugins" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jmeter-plugin...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages