1

I'm trying to run JMeter in non-GUI mode but I want to generate two result files: one in CSV format and another in JTL (but using XML).

Right now I have:

jmeter -n -t C:\testPlan.jmx -l C:\result.jtl

Of course, trying -l is not valid. Is there a way to set it so that I can have both formats produced without running the test twice with different configurations?

fixer1234
  • 28,064
dhuynh
  • 13

1 Answers1

1

It's quite simple:

  1. Add a Simple Data Writer listener to your test plan
  2. Provide path to XML results file in "Filename" input
  3. Click "Configure" button
  4. Make sure that "Save As XML" box is checked
  5. Tick other boxes according to metrics you would like to capture

Example configuration:

Simple Data Writer configuration

Be aware that storing results in XML is more resource consuming process, especially if you decide to store response data for all requests, massive IO activities may interfere load test flow and may ruin your test.

I would recommend storing just the necessary minimum of data and enable verbose logging only if you need to analyze some failure.

Example "good" configuration regarding which values are safe to save is listed in the JMeter Performance and Tuning Tips guide along with the other recommendations on how to properly configure JMeter instance(s)

Dmitri T
  • 596