JMeter Interview questions for freshers/Jmeter Interview Questions and Answers for Freshers & Experienced

How to perform Spike Testing in JMeter?

By synchronizing, timer JMeter spike testing can be achieved. Synchronizing timer, blocks thread until a specific amount of threads has been blocked and then release them all together thus creating large instantaneous load.

Do we need to learn coding to create scripts in JMeter?

Script creation in JMeter is somewhat different from normal automated script creation. Mostly, a script can be created by recording or using JMeter UI. Followed by parameterization of tests, correlation, and configuration of different test parameters.
Having said that, coding is required in some scenarios and can be done with Beanshell scripting.

Explain the Ramp-up period?

When it comes to testing the loading of an app, only a few users are considered then all for effectively studying the behavior of the app. This also derives a lot of useful information to know the overall performance of the app. Of course, it takes some time in making all the users in the running state. This time period is generally called the Ramp uptime. It is different from different apps depending on the overall number of users, data, and several other factors.

How do you ensure re-usability in your JMeter scripts?

<> Using config elements like "CSV Data Set Config", "User Defined Variables", etc for greater data reuse.

<> Modularizing shared tasks and invoking them via a "Module Controller".

<> Writing your own BeanShell functions, and reusing them.

What do you know about the correlation?

It is basically a process of enticing the data from the previous calls and then sending it to consecutive requests in the form of parameters. It is very helpful in making the scripting easy and the good this is it cut a lot of complexity from the process of handling sessions.

How do you ensure re-usability in your JMeter scripts?

You can ensure re-usability in the following ways:

1. Using config elements like “CSV Data Set Config“, “User Defined Variables“, etc for greater data reuse.

2. Modularizing shared tasks and invoking them via a “Module Controller“.

3. Writing your own BeanShell functions, and reusing them.

How would you do master-slave configuration in Jmeter?

Master-Slave configuration is considered as a part of Distributed Testing in which case more than one machine is used to perform load testing of the server under test. Such that it becomes important that all machines are on the same network and all have the same version of Jmeter. Also in distributed testing, one machine is made as the Master and the others are kept as slaves by doing some configurations.

Steps to perform master-slave configuration are -

1. Edit the jmeter.properties file on the master machine, and add the IP addresses of slave machines against the remote_host field in the file.

2. Next save the file and open the Jmeter again.

3. Now from the RUN menu in Jmeter, select Remote Start and choose the IP of the machine to be invoked.

4. Choose RUN menu and select Remote Start all to start all the slave machines for testing.

How can Jmeter record actions from Mobile?

Jmeter can record HTTP or https request going to the server from your mobile application also. Therefore Mobile and Jmeter should be on the same network.

The configuration required to record actions from Mobile,

1. First configure the proxy server in JMeter to run at a specified port.

2. Second set up a proxy on the mobile wifi settings and then enter the same port number that is used in the recorder.

3. Third install the Root CA certificate on the mobile.

4. Fourth hit server request from the mobile and observe it getting captured by the specified controller.

What is the primary use of co-relation in Jmeter?

Co-relation is basically a process in which the values can be extracted from the server response and stored in a variable which is then then used in any other request which is to follow.

For instance in order to test any login functionality if you have to use session ID/cookie ID , you can then extract the value from the response of GET request of the login page and then dynamically use the same while making POST request for login.

Explain what is the role of Timer in JMeter?

With the help of a timer, JMeter can delay the time between each request, which a thread makes. It can solve the overload problem of the server.

Explain the difference between Gaussian and Poisson Timers.

Both Gaussian and Poisson Timers work on a mathematical formula with some constant delay and additional offset. Difference between the two lies in the fact that how the lambda value is calculated in the case of Poisson timer and how deviation is calculated in the case of Gaussian Timer.

In JMeter is it necessary to call embedded resources explicitly?

You can eliminate all embedded resources from being explicitly called. Requests have a checkbox at the bottom that says “retrieve embedded resources.” It would grab all CSS, JPG, etc. It is a brilliant way to find resources and broken link in a web App.

What is distributed load testing? How can it be achieved?

Distributed load testing is the process through which numerous systems can be used for simulating a load of a large number of users. By using the master-slave configuration, JMeter can do distribute load testing.

Explain how you can capture the script of the authentication window in JMeter?

Normally, you can capture script by recording.

<> First, you have to Threadgroup in Testplan and then make HTTPProxyServer in Workbench.

<> After that, set port number in the Global Setting box (e.g., 8911) and modify your connection setting in IE as localhost in address 8911 as in port Then you can start http proxy server in JMeter and run your application for login.

What are the maximum recommended threads on a single system?

It depends on the hardware configuration of your system which includes a processor, JVM, allocated memory -Xmx, etc.

Other factors that impact thread count are the number of components in your test plan i.e. the number of config elements or processors and it also depends on whether you are using GUI/Non-GUI Mode.

Explain how you can perform spike testing in JMeter?

By synchronizing, timer JMeter spike Testing can be achieved. Synchronizing timer blocks thread until a specific amount of threads has been blocked and then release them all together thus creating large instantaneous load.

Explain how you can reduce the resource requirement in JMeter?

To reduce the resource requirements in JMeter

<> Use non-GUI mode: jmeter –n –t test.jmx –l test.jtl.
<> During the load, a test doesn’t use “view results tree” or “view results in table” listeners, use them only during the scripting phase.
<> Don’t use functional mode.
<> Instead of using lots of similar samplers, use the same sampler in a loop and use the variable to vary the sample.

Explain what is Test Fragment?

Test fragment is also a type of element like Thread Group element. The only difference is test fragment is not implemented unless it is referenced by either a Module controller or an Include controller.

What is the execution order of Test Elements

Following is the execution order of the test plan elements:

1. Configuration elements

2. Pre-Processors

3. Timers

4. Sampler

5. Post-Processors (unless SampleResult is null)

6. Assertions (unless SampleResult is null)

7. Listeners (unless SampleResult is null)

What is Configuration element?

Configuration Elements allow you to create defaults and variables to be used by Samplers. They are used to add or modify requests made by Samplers.

They are executed at the start of the scope of which they are part, before any Samplers that are located in the same scope. Therefore, a Configuration Element is accessed only from inside the branch where it is placed.

What are Controllers and its types?

JMeter has two types of Controllers:

<> Samplers Controllers : Samplers allow JMeter to send specific types of requests to a server. They simulate a user's request for a page from the target server. For example, you can add a HTTP Request sampler if you need to perform a POST, GET, DELETE on a HTTP service

<> Logical Controllers : Logic Controllers let you control order of processing of Samplers in a Thread. Logic Controllers can change the order of request coming from any of their child elements. Some examples are: ForEach Controller, While Controller, Loop Controller, IF Controller, Run Time Controller, Interleave Controller, Throughput Controller, Run Once Controller.

What is Thread Group?

Thread Group elements are the beginning points of your test plan. As the name suggests, the thread group elements control the number of threads JMeter will use during the test.

What are the protocols supported by JMeter?

The protocols supported by JMeter are:

Web: HTTP, HTTPS sites 'web 1.0' web 2.0 (ajax, flex and flex-ws-amf)

Web Services: SOAP / XML-RPC

Database via JDBC drivers

Directory: LDAP

Messaging Oriented service via JMS

Service: POP3, IMAP, SMTP

FTP Service

What is Stress Test?

This test is an attempt to break the system by overwhelming its resources.

What is Load Test?

This test is basically used for exercisingdiscovering the system under the top load it was designed to operate under.

What are the types of processors in JMeter?

Basically there are two types of processors in JMeter namely Pre-Processor and Post Processor.

Pre-Processors execute before the main sampler and can change the scope of the sampler whereas Post Processors execute after the main sampler and are applicable to all samplers in the same scope of Test Plan. They can be used to extract some fields from the server response and store them in variables.

How requests are sent to the server in JMeter?

Basically, this is done with the help of Samplers. There are several samplers that are present in the JMeter and a few of them that are used commonly are:

1. Junit request
2. JDBC request
3. HTTP request

What is a Timer in JMeter? What are the types of it?

A JMeter thread by default will send requests continuously without any pause. Timers are used to get a pause between the request.

The different types of Timer in JMeter are:

>> Constant Timer – This element delays each request in a Thread Group for the same amount of time.
>> Gaussian Timer – This element is used to delay each user request for a random period of time.
>> Synchronizing Timer – This element is used to release number of threads at given point.
>> Uniform Random Timer – This element is used to delay each request for a random period of time.

Explain what is a timer in JMeter and what are the types of it?

A JMeter thread by default will send requests continuously without any pause. To get a pause between the request, Timers are used. Some of the Timers used are Constant Timer, Gaussian Random Timer, Synchronizing Timer, Uniform Random Timer and so on.

Explain what is the configuration elements?

A configuration element works parallel with a Sampler. To set up defaults and variables for later use by samplers configuration elements can be used. At the start of the scope, these elements are processed before any samplers in the same scope.

What does “contain” and “matches” indicates in the regular expression?

In the regular expression, contains indicates that the regular expression matched at least some part of the target. While matches mean the regular expression matched the whole target. So, ‘alphabet’ is “matched” by ‘al.*t.’

Explain what are Pre-processor Elements? List some of the pre-processor elements?

A pre-processor is something that will happen before the sampler executes. To configure the sample request prior to its execution or to update variables that are not extracted from response text pre-processor elements are used.

Some of the pre-processor elements are

<> HTTP URL re-writing modifier
<> HTTP user parameter modifier
<> HTML link parser
<> BeanShell PreProcessor

What are the types of processor in JMeter?

The two types of JMeter are:

<> Pre-processor

<> Post processor

What is the use of Regular Expression in JMeter?

Regular Expression is used for extracting some values dynamically from the responses.These values can be used in the subsequent request or can be saved for reporting purposes. Regular Expression is used in both Pre-Processors as well as Post Processors.

Whether the test plans built using JMeter are OS dependent?

Usually, Test Plan are saved in their XML format, so there is nothing to do with any particular O.S. It can be run on any OS where JMeter can run.

What is Distributed testing?

Distributed Testing means using multiple machines for load testing in which one of the machines can be made master and others can be kept as a slave. It is very important to note that all the machines should be on the same network and should have the same version of Java and JMeter.

What are Samplers & Thread Groups?

Samplers – Sampler generates one or more sample results. These sample results have many attributes like elapsed time, data size, etc. It allows JMeter to send specific types of requests to the server, through samplers, thread group decides which type of request it need to make. Some of the useful samplers are HTTP request, FTP request, JDBC request etc.

Thread Groups – JMeter is the beginning part of thread group elements. It is an important element of JMeter, where you can set number of users and time to load all the users given in the thread group.

How many maximum threads are recommended on a single system?

The recommendation of maximum threads on a single system is based on the hardware configuration of the system which includes a processor, JVM, allocated memory -Xmx, etc.

There are other factors as well that impact this such as the number of components in the test plan like the number of config elements or processors and it also depends on whether you are using GUI/Non-GUI Mode.

What are the different methods used in Data Parametrization in Jmeter?

The objective of data parametrization is to make the scripts reusable where the values need not be hardcoded for the same request with different parameters.

The data parametrization that is supported in Jmeter are -

1. CSV Data Set Config

2. User Defined Variables

What is a Test Plan in JMeter?

A Test Plan provides a layout of the web application as well as the client-server application. It can be viewed as a container for running tests. A complete test plan will consist of one or more elements such as thread groups, logic controllers, sample-generating controllers, listeners, timers, assertions, and configuration elements. A test plan must have at least one thread group.

What are the Protocols supported by JMeter?

The protocols supported by JMeter are:

* Web: HTTP, HTTPS sites ‘web 1.0’ web 2.0
* Web Services: SOAP / XML-RPC
* Database via JDBC drivers
* Directory: LDAP
* Messaging Oriented service via JMS
* Service: POP3, IMAP, SMTP
* FTP Service

What are Regular Expressions in JMeter?

Regular Expressions are used to search and manipulate text. JMeter is used for interpreting forms of regular expression or patterns being used throughout a JMeter test plan.

How can Jmeter simulate actual browser behavior?

Jmeter does not support the actual browser behavior as it does not render the HTML webpages as the normal browser.

Such that response can be seen in HTML format but the actual timings are not there in the generated samples.

Does JMeter simulate actual browser behavior?

No, JMeter does not support the actual browser behavior. It does not render the HTML webpages as the normal browser does. The response can be viewed in HTML format but the actual timings are not present in the generated samples.

Mention what are regular expressions in JMeter?

Based on the pattern, a regular expression is used to search and manipulate text. JMeter is useful in interpreting forms of regular expression or patterns being used throughout a JMeter test plan.

Explain where you can use functions and variables?

Variables and functions can be written into any field of any test component.

Explain how JMeter works?

JMeter acts like a group of users sending requests to a target server. It collects response from the target server and other statistics which show the performance of the application or server via graphs or tables.

Explain the architecture of JMeter.

Jmeter is a Java-based open-source application that is basically designed for the purpose of Load Testing. It supports all major protocols that are supported in Load Runner. Unlike any browser, JMeter works on levels of protocols and does not execute JavaScript present in HTML web pages.

Explain what is JMeter?

JMeter is a Java tool, which is used for performance Load Testing.

Search
R4R Team
R4R provides Jmeter Freshers questions and answers (Jmeter Interview Questions and Answers) .The questions on R4R.in website is done by expert team! Mock Tests and Practice Papers for prepare yourself.. Mock Tests, Practice Papers,JMeter Interview questions for freshers,Jmeter Freshers & Experienced Interview Questions and Answers,Jmeter Objetive choice questions and answers,Jmeter Multiple choice questions and answers,Jmeter objective, Jmeter questions , Jmeter answers,Jmeter MCQs questions and answers Java, C ,C++, ASP, ASP.net C# ,Struts ,Questions & Answer, Struts2, Ajax, Hibernate, Swing ,JSP , Servlet, J2EE ,Core Java ,Stping, VC++, HTML, DHTML, JAVASCRIPT, VB ,CSS, interview ,questions, and answers, for,experienced, and fresher R4r provides Python,General knowledge(GK),Computer,PHP,SQL,Java,JSP,Android,CSS,Hibernate,Servlets,Spring etc Interview tips for Freshers and Experienced for Jmeter fresher interview questions ,Jmeter Experienced interview questions,Jmeter fresher interview questions and answers ,Jmeter Experienced interview questions and answers,tricky Jmeter queries for interview pdf,complex Jmeter for practice with answers,Jmeter for practice with answers You can search job and get offer latters by studing r4r.in .learn in easy ways .