{"id":34059,"date":"2016-05-04T10:18:32","date_gmt":"2016-05-04T04:48:32","guid":{"rendered":"http:\/\/www.tothenew.com\/blog\/?p=34059"},"modified":"2017-04-17T15:58:47","modified_gmt":"2017-04-17T10:28:47","slug":"jmeter-master-slave-setup-in-multiple-aws-regions","status":"publish","type":"post","link":"https:\/\/www.tothenew.com\/blog\/jmeter-master-slave-setup-in-multiple-aws-regions\/","title":{"rendered":"JMeter Master Slave Setup In Multiple AWS Regions"},"content":{"rendered":"<p>In this blog, I\u2019ll be demonstrating how to set up master-slave JMeter set up in multiple AWS regions. The aim is to generate load from multiple regions or multiple AZs in order to get a flavour of real load. For this purpose I am using EC2 servers, so a master server in Oregon region and the slave is running in N.Virginia region.<\/p>\n<p><strong>Image Source:<\/strong>\u00a0http:\/\/gerardnico.com\/wiki\/jmeter\/remote<\/p>\n<p>Here are the details:<br \/>\n<strong><span style=\"color: #f60;\">Master server:<\/span><\/strong><br \/>\nIP: 52.88.159.81<br \/>\nRegion: Oregon<\/p>\n<p><strong style=\"line-height: 1.71429; font-size: 1rem;\"><span style=\"color: #f60;\">Slave server:<br \/>\n<\/span><\/strong><span style=\"line-height: 1.71429; font-size: 1rem;\">IP: 52.71.163.50<br \/>\n<\/span><span style=\"line-height: 1.71429; font-size: 1rem;\">Region: N.Virginia<\/span><\/p>\n<p>I am using the same version of JMeter on both the servers. By default, the JMeter invocation works on the instance\u2019s private IP that is why the master-slave instances are able to communicate with each other if they are in the\u00a0same VPC, but when we span the set up to multiple VPCs or even regions then the same thing with private IP doesn\u2019t work. For this purpose, we have to invoke the JMeter daemons on their public IP so that they can communicate with each other on their public IP.<\/p>\n<p>For this purpose, we have to make some changes in the configuration. To invoke jmeter daemon over its public IP, we have to set a parameter \u201c-Djava.rmi.server.hostname=\u201d on the command on both the master and slave servers.<\/p>\n<p>So the steps are listed below:<br \/>\n1. First, we have to trigger the JMeter daemon of the slave server on its public IP:<\/p>\n<p>[js]sudo \/usr\/share\/jmeter\/bin\/jmeter-server -Djava.rmi.server.hostname=52.71.163.50<br \/>\n[\/js]<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone  wp-image-34107\" src=\"\/blog\/wp-ttn-blog\/uploads\/2016\/05\/slave-invocation.png\" alt=\"slave-invocation\" width=\"1377\" height=\"44\" \/><\/p>\n<p>2. Then run the load test from master after invoking it on its public IP:<\/p>\n<p>[js]jmeter -n -t load-test.jmx -R 52.71.163.50 -Djava.rmi.server.hostname=52.88.159.81<br \/>\n[\/js]<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone  wp-image-34106\" src=\"\/blog\/wp-ttn-blog\/uploads\/2016\/05\/master-invocation.png\" alt=\"master-invocation\" width=\"646\" height=\"127\" \/><\/p>\n<p>On Slave&#8217;s side:<\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone  wp-image-34105\" src=\"\/blog\/wp-ttn-blog\/uploads\/2016\/04\/slave-result.png\" alt=\"slave-result\" width=\"1049\" height=\"57\" \/>After following these steps, you should be able to run the master slave load test setup in multiple regions.<\/p>\n<p><span style=\"color: #f60;\"><span style=\"color: #000000;\">To know more about the best practices of Load testing,<\/span> <a href=\"http:\/\/www.tothenew.com\/blog\/7-things-you-must-know-about-load-testing-using-jmeter\/\">click here. <\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this blog, I\u2019ll be demonstrating how to set up master-slave JMeter set up in multiple AWS regions. The aim is to generate load from multiple regions or multiple AZs in order to get a flavour of real load. For this purpose I am using EC2 servers, so a master server in Oregon region and [&hellip;]<\/p>\n","protected":false},"author":170,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"iawp_total_views":17},"categories":[1174,2348,1],"tags":[3278,696,3275,698,3263,3277,3276],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/34059"}],"collection":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/users\/170"}],"replies":[{"embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/comments?post=34059"}],"version-history":[{"count":0,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/posts\/34059\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/media?parent=34059"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/categories?post=34059"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.tothenew.com\/blog\/wp-json\/wp\/v2\/tags?post=34059"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}