How Jmeter handles LDAP Referral mechanism - jmeter

I am trying to do a LDAP mod operation through Jmeter. Expected behavior - Jmeter would hit server A which in turn would hit server B. Actual modification operation would happen at server B. Server B would complete the operation and give response to server A which in turn would respond to Jmeter.
Now the issue is, Jmeter is always getting the "Referral" response message. However, manually we are able to change the password after hitting server A from different remote server.
Could you someone please suggest how to overcome this?

I am assuming this has been resolved. Just in case you are still wondering, #Rohan , my understanding is that you run jmeter on the command line:
$ jmeter -Jjava.naming.referral=true -n -t testplan.jmx -l log.jtl

JMeter won't have specific behaviour of its own. You will need to tell it to follow referrals by setting java.naming.referral property appropriately in the jndi.properties mechanism defined in the documentation for the JNDI LDAP provider, which you should already have in place for your application if you expect it to behave that way.

Related

Issue with Jmeter SSHMON sample collector ( received data is not parsed by the plugin)

I’m doing a performance test using Jmeter and during the test I’m collecting the statistics for backend server performance , for this purpose I use SSHMON sample collector listener in my test plan
https://github.com/tilln/jmeter-sshmon
I have also configured a CSV file path to check the response data received from the server
Issue is that
Data is not recorded in the CSV file and also there is no graph shown for SSHMON listener
In the jemeter logs I can see the following error
java.text.ParseException: Unparseable number: " [2J"
at java.text.NumberFormat.parse(NumberFormat.java:434) ~[?:?]
at nz.co.breakpoint.jmeter.vizualizers.sshmon.SSHMonSampler.generateSamples(SSHMonSampler.java:86) [jmeter-sshmon-1.2.jar:?]
at kg.apc.jmeter.vizualizers.MonitoringResultsCollector.processConnectors(MonitoringResultsCollector.java:215) [jmeter-plugins-cmn-jmeter-0.6.jar:?]
at kg.apc.jmeter.vizualizers.MonitoringResultsCollector.run(MonitoringResultsCollector.java:122) [jmeter-plugins-cmn-jmeter-0.6.jar:?]
at java.lang.Thread.run(Thread.java:832) [?:?]
To verify the SSH configuration and the received data format , I tried to make a SSH connection to the backend server using putty and with same user/pwd and command , I get the data in Putty , please see the attached screenshot
Do I have to change the powershell script to change the format of CPU data, if yes then in which format?
I did not get any info on plugin page.
I would really appreciate if you could provide me some help for this case.
The reason for this issue appears to be related to the terminal control sequence sent
as output of the remote Powershell server application back to the local client,
i.e. the JMeter plugin vs. the Powershell command line.
The characters [2J would be the "Erase in Display" sequence (refer ANSI Escape Codes, e.g. https://en.wikipedia.org/wiki/ANSI_escape_code#CSI_sequences).
In one case those characters would presumably be interpreted by the terminal application displaying the output (e.g. Putty or Cmd window) and the output looks correct.
In the other case however, the control sequence characters are received by the plugin and rejected as unparsable number.
A very similar issue has been reported on the JMeter-Plugins Google Group.
The version 1.3 of the SSHMon plugin uses a different SSH client library which seems to fix the issue according to feedback on the Google Groups thread.
Recommended solution: Upgrade to version 1.3 or later.
Disclaimer: I'm the author of the JMeter SSHMon plugin.

Unable to Execute Distributed Testing in JMeter 4.0

I have applied all the instructions to execute the distributed Testing for JMeter.
But When I run as "Remote Start-XXX.XXX.XXX.XXX"
Then I am getting "Exception creating connection: XXX.XXX.XXX.XXX; nested exception is: java.io.IOException: java.security.UnrecoverableKeyException: Cannot recover key".
Can anyone help me Why I am getting that exception?
Reference that I used: LINK
This is how I solve the same problem as yours. Have a try, hope this can help:
when answering the question What is your first and last name?, you'll have to reply with rmi which is a corresponding value with server.rmi.ssl.keystore.alias in jmeter.propertise. Remember do NOT enter any custom value if u have not changed the server.rmi.ssl.keystore.alias in jmeter.propertise when u are trying to create a keystore.
Given you use JMeter 4.0 additionally you need to follow steps from Setting Up SSL User Manual Chapter
Alternatively if you don't want secure RMI communication between master and slave(s) you can add the next line to user.properties file
server.rmi.ssl.disable=true
or pass it via -J command-line argument like:
jmeter -Jserver.rmi.ssl.disable=true
The change has to be done on all engines (master and all the slaves)
References:
Remote hosts and RMI configuration
Configuring JMeter
In JMeter 4.0 you need to generate a keystore that will be used in distributed testing.
Follow this tutorial instead:
http://jmeter.apache.org/usermanual/jmeter_distributed_testing_step_by_step.html
Pay particular attention to:
https://jmeter.apache.org/usermanual/remote-test.html#setup_ssl

Using SSHMon plugin with Jmeter- Plugin not capturing any stats

I have been working on Jmeter from quite sometime now and I have been trying to use Jmeter Plugin SSHMon , but I am stuck as even after configuring it completely it simply says "Waiting for samples" and does not render anything on the graph.
I am trying to execute the command on the Linux box and have passed all the relevant parameter for collecting the stats. But still I am not able to capture anything. Any help or pointer will be appreciated.
I also tried connecting the Linux box using Putty and executing the command and the command does work, but when I execute the test the Plugin does not capture anything
Please find the ScreenShot attached
In the majority of cases the answer lives in jmeter.log file, check it for any suspicious entries, if something is not working most probably there will be a cause identifier there. Also make sure to actually run your test as SSHMon is a Listener and relies on Sampler Results so if your test is not running - it will not show anything.
As an alternative you can use JMeter PerfMon Plugin which has EXEC metric so you can collect the same numbers, however PerfMon will require Server Agent to be up and running on the remote Linux system.
After a lot of trail and error I was able to get SSHMon working. Please find the solution below
Ok Guys, so its a lot tricky as you would expect. So I thought that installing the Perfmon Agent on the server made Jmeter collect the stats for SSHMon listner but there is a catch to it. To start off I will let you know that installing the Perfmon Agent on the servers and then using the plugin to collect the stats works smooth. You can definately use this option. But it requires for the Agent to be started everytime you want to run a test and if there are multiple servers you will have to restart on those server. Not sure if there is a way to automate the restart of the agent or to keep it running for a longer time. If you are lazy like me or you have installation restriction on the servers or hell bent on using SSHMon then what you need to do is stated below.
You should always start Jmeter with the command line argument --->
jmeter -H "Proxy" -P "Port" -u "UserName" -a "Password"
The arguments are self explanatory. Once you do that Jmeter will be launched, but wait its not done yet!!
When you start executing your test the command prompt in which you have started the Jmeter will prompt for Kerberos UserName [YourUsername]: you have to again Enter you username here, which you use to start Jmeter or login to you system. Followed by this it will prompt you to enter kerberos Password for your UserName: Enter Your Password and Voila!!
The thing is, it happens in the background so you never see what is happening on the Command Prompt you used to start Jmeter.
Please see below for more clarity.
Kerberos Username[UserName]: UserName Kerberos
Password for UserName: Password
I have attached the screen shot as well in the question as well as here showing the issue being resolved. Please refer "Solution ScreenShot". Cheers!!
Hope this helps Guys!! :)
Also please hit up for the answer if it helps you!! :)

Jmeter testing on multiple websites on the same server

I have a working script to login and get to one website on the webserver, what I need is how to get to the other 10 plus servers with Jmeter all at once to do a nice stress test on the websites and its interfaces.
Any help is greatly appreciated
I think that you need to use DNS Cache Manager available since JMeter 2.12
DNS Cache Manager allows each JMeter thread to resolve underlying IP address of the request endpoint on its own.
See The DNS Cache Manager: The Right Way To Test Load Balanced Apps guide for detailed explanation of background and configuration details.
This is pretty trivial using the CSV Data Set Config.
Let's assume you are using normal HTTP Request samplers and that these are already set up with a server and path. Let's say it is the server you want to change for each thread. Then you need to:
Create a text file with a different server you want to test on each line.
Add a CSV Data Config element to the top level.
Configure the CSV Data Config to use your text file and set the variable name of server.
In your samplers change the server name to ${server}.
You can use the same method to change the path and other details.

Jmeter test fail on same app different servers (Spring webflow + Primefaces)

I'm having a weird problem with JMeter.
Scenario:
Web app running on localhost
Record a simple test on Jmeter (login + 1 search)
Execute the test on localhost with Jmeter. Test runs OK.
Change the server and port on HTTP Request Defaul for another server's IP and port running the same version of the app.
The test runs but fails at the search with ".FlowExecutionRestorationFailureException: A problem occurred restoring the flow execution with key 'e3s2'"
If i do the same swapging servers (record on remote server and try to execute on local) the behavior is the same.
¿Any clues of what can it be? I don't understand why it manages to do the login and navigate on another server but fails on other action.
In short, if I record a test it fails at somepoint if I change the server.
Software_
Jmter 2.12
Primefaces 5.0
Spring Webflow 2.3.1.RELEASE
Apache Tomcat 7.0
My expectation is that there is at least one dynamic parameter which is currently being hardcoded into your script. I would suggest to do the following:
Record your login+search flow once again
Inspect 2 .jmx scripts to detect any differences (i.e. one or more parameters having different values)
Once you find those problematic parameters you'll need to look into server's response body/headers/cookies/ to see where it lives.
As soon as you know where the parameter value lives you can use one of the following PostProcessors:
Regular Expression Extractor
XPath Extractor
CSS/JQuery Extractor
The whole process is called "correlation" so you can use "JMeter correlation" as a search term if above information is not enough to resolve your problem.
The problem was some xhtml components that didn't had any specified Id so jsf would set something like id="mainForm:j_idt12". Since my test don't need to work on dynamic generated html (are simple tests) setting the ids solve the poblem.

Resources