Im working with JMeter and Taurus to run a couple of .jmx test created from JMeter, but when I run the following command:
bzt xxxxx.jmx -report
I got this error:
14:50:54 INFO: Taurus CLI Tool v1.12.0
14:50:54 INFO: Starting with configs: ['C:\\Users\\excmapi\\AppData\\Local\\Temp\\jmx_cm6_v7pt.json']
14:50:54 INFO: Configuring...
14:50:54 INFO: Artifacts dir: \Downloads\2018-06-29_14-50-54.858323
14:50:54 INFO: Preparing...
14:50:55 ERROR: UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 289636: character maps to <undefined>
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\cli.py", line 249, in perform
self.engine.prepare()
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\engine.py", line 169, in prepare
self.__prepare_provisioning()
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\engine.py", line 515, in __prepare_provisioning
self.provisioning.prepare()
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\modules\provisioning.py", line 72, in prepare
executor.prepare()
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\modules\jmeter.py", line 267, in prepare
scenario = self.get_scenario()
File "\appdata\local\programs\python\python36-32\lib\site-packages\bzt\modules\jmeter.py", line 209, in get_scenario
script_content = fds.read()
File "\appdata\local\programs\python\python36-32\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
14:50:55 INFO: Post-processing...
14:50:55 INFO: Artifacts dir: \Downloads\2018-06-29_14-50-54.858323
14:50:55 WARNING: Done performing with code: 1
The line which give the error are a lot. One of they is the next:
<elementProp name="ID_1{omR|i}s" elementType="HTTPArgument">
I've search a lot in internet, but I dont find a solution for this issue. One of the possible cause of this issue which I finded is that when the .jmx file is created, some tags have correlation, so when I want to run the script with Taurus (Python), the console display that issue.
Here the link
One of the solution for this issue is using a tool of Blazemeter which you can see in the mentioned link what allow to create a proxy and record the test, but it isn't work to me, because I want to solve this issue without another tool.
Exist some way to fix this then the jmx script was created without add more configuration in JMeter?
I hope you can help me, thanks a lot!
Regarding your title issue , There is a bug in Taurus, see:
https://groups.google.com/forum/m/#!topic/codename-taurus/p2J1fpx04KI
Could you try the latest snapshot and report result?
(http://gettaurus.org/docs/DeveloperGuide/)
Related
I am trying to generate html report using robotframework but getting below error
JMeterLibException: 'No samples were found in a log file.'
Command used :
Run Jmeter ${jmeter} ${jmxPath} ${logPath} -JudvData=${excelData} -Jport=${port} -Jurl=${url} -JSMS.group=1
Analyse Jtl Convert To Html ${logPath}
jtl file is getting generated successfully but facing issue will converting jtl to HTML
Below is the log details ,
If there are no results it means that JMeter script execution has failed somewhere somehow, in this case you can check:
Robot Framework log file
JMeter log file
If you cannot figure out what's wrong from the JMeter log file it is possible to increase logging verbosity either for individual components or for the overall application via log4j2.xml file (lives in "bin" folder of your JMeter installation), see How to Configure JMeter Logging article for more details.
The most common reasons are:
The number of threads (virtual users) or loops (iterations) in Thread Group is 0
Missing data file referenced in CSV Data Set Config
Missing JMeter Plugin
I am using MSBuild. I have Java 8 installed.
I am running the following commands:
SonarQube.Scanner.MSBuild.exe begin /k:"ABC" /d:sonar.host.url="http://localhost:9000" /d:sonar.login="8b839xxxxxxxxxxxxxxxxxxxxxxx6b00125bf92" /d:sonar.verbose=true
"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\MSBuild\15.0\Bin\msbuild.exe" /t:rebuild
SonarQube.Scanner.MSBuild.exe end /d:sonar.login="8b839xxxxxxxxxxxxxxxxxxxxxxx6b00125bf92"
The last step fails:
ERROR: Error during SonarQube Scanner execution
ERROR: The 'report' parameter is missing
ERROR:
ERROR: Re-run SonarQube Scanner using the -X switch to enable full debug logging.
The SonarQube Scanner did not complete successfully
12:53:21.909 Creating a summary markdown file...
12:53:21.918 Post-processing failed. Exit code: 1
The MSBuild version is greater than 14.
Java 8 is properly installed. Documentation indicates that Java 8 is adequate.
Any idea on what could be wrong?
Where do I add the -X switch? I tried on all 3 statements
Update :I installed Java SDK 9. Still same issue.
Update :With verbose logging and using /n naming parameter:
INFO: Analysis report generated in 992ms, dir size=4 MB
INFO: Analysis reports compressed in 549ms, zip size=1 MB
INFO: Analysis report generated in C:\ABC\.sonarqube\out\.sonar\scanner-report
DEBUG: Upload report
DEBUG: POST 400 http://localhost:9000/api/ce/submit?projectKey=ABC | time=1023ms
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 54.833s
INFO: Final Memory: 51M/170M
INFO: ------------------------------------------------------------------------
DEBUG: Execution getVersion
DEBUG: Execution stop
ERROR: Error during SonarQube Scanner execution
ERROR: The 'report' parameter is missing
ERROR:
ERROR: Re-run SonarQube Scanner using the -X switch to enable full debug logging.
Process returned exit code 1
The SonarQube Scanner did not complete successfully
Creating a summary markdown file...
Post-processing failed. Exit code: 1
I've struggled the same problem with SonarQube and I've finally found a solution:
You need to restart sonar service after using evaluation token.
Please note this isn't the answer, however I feel this feedback is valuable to getting this question answered.
I can reproduce this issue in POSTMan with a POST request to:
http://localhost:9000/api/ce/submit?projectKey=myProjectKey
This returns
{
"errors": [
{
"msg": "The 'report' parameter is missing"
}
]
}
You can get a similar error by removing the projectKey query parameter. I tried adding a report query parameter and received the same error:
http://localhost:9000/api/ce/submit?projectKey=brian3016&report=report
Given this, I feel there is a problem with their code. It should have included a report parameter when creating the POST request, but it failed to do so.
Verbose output seems to have changed from using the -X switch to /d:sonar.verbose=true. E.G.
SonarScanner.MSBuild.exe begin /k:"myProjectKey" /d:sonar.host.url="http://localhost:9000" /d:sonar.login="myLogin" /d:sonar.verbose=true
Note the verbose logging didn't give me any valuable insight.
(Also note that the documentation currently says to use SonarQube.Scanner.MSBuild.exe, but the verbose logger told me to switch to SonarScanner.MSBuild.exe)
SO...how we we report this issue to someone that can fix it? Their documentation says to go to Stackoverflow. So here we are.
I thought it may have been an issue with a project. So I created a new project with nothing other than the startup template Console Application. Same error.
In my case SonarQube 7.9.1 (deployed with Helm to Kubernetes cluster) was missing temp directory /opt/sonarqube/temp/tc/work/Tomcat/localhost/ROOT after Helm rollback. No idea what happened to it.
Logfile /opt/sonarqube/logs/web.log inside SonarQube pod had this error:
2021.02.02 06:57:03 WARN web[AXdZ6l6MParQCncJACv3][o.s.s.w.ServletRequest] Can't read file part for parameter report
java.io.IOException: The temporary upload location [/opt/sonarqube/temp/tc/work/Tomcat/localhost/ROOT] is not valid
The fix was to exec into pod and create the missing directory. Would like to know the reason though...
The issue is with the sonar service starting up.
First try to stop the SonarStart.bat by using Ctrl+c, and then try to open localhost:9000 ( or whichever port you configured sonar server).
If it is still opening then go to task manager and search for wrapper.exe service and stop the service. If no service is found then go to:
Task manager>Details> and stop all java.exe process.
Note: If you running many Java applications, right-click the java.exe and choose goto service, and stop only those java.exe that belongs to AppX deployment.services
Now start sonarstart.bat as administrator..
today i face the same error when using jenkins to scanner the code.
get the error when POST /api/ce/submit and get 400 code by add the sonar.verbose=true
i use the below step to check reason
first to restart the sonarqube => failed
check the report file size by using "du -sh" get 108m and DB server support 1G => failed
login the sonar-qube server and check the access.log, web.log and another log, finally find the error reason " Processing of multipart/form-data request failed. No space left on device", so i check the server by command "df -h", some devices are used 100% => so i remove some no-using file and fix it!!!
check if you have enough memory
ex: free -m
In my case I had to upgrade memory.
I am trying to run my Test.jmx file through below ant cmd:
C:\apache-ant-1.10.1-bin\bin>ant
I got the following error:
C:\apache-ant-1.10.1-bin\bin>ant
Buildfile: C:\apache-ant-1.10.1-bin\bin\build.xml
run:
[echo] funcMode = false
[jmeter] Executing test plan: C:\apache-ant-1.10.1-bin\bin\Test.jmx ==> C:\apache-ant-1.10.1-bin\bin\Test.jtl
_message_xalan:
xslt-report:
BUILD FAILED
C:\apache-ant-1.10.1-bin\bin\build.xml:124: input file C:\apache-ant-1.10.1-bin\bin\Test.jtl does not exist
Total time: 4 seconds
C:\apache-ant-1.10.1-bin\bin>
I fixed this issue by creating a new Test.jtl file.
Now I am getting this error:
C:\apache-ant-1.10.1-bin\bin>ant -Dtestpath=C:\apache-ant-1.10.1-bin\bin\ -Dtest=Test
Buildfile: C:\apache-ant-1.10.1-bin\bin\build.xml
run:
[echo] funcMode = false
[jmeter] Executing test plan: C:\apache-ant-1.10.1-bin\bin\Test.jmx ==> C:\apache-ant-1.10.1-bin\bin\Test.jtl
_message_xalan:
xslt-report:
[xslt] Processing C:\apache-ant-1.10.1-bin\bin\Test.jtl to C:\apache-ant-1.10.1-bin\bin\Test.html
[xslt] Loading stylesheet C:\apache-ant-1.10.1-bin\bin\jmeter-results-report_21.xsl
[xslt] C:\apache-ant-1.10.1-bin\bin\Test.jtl:1:1: Fatal Error! Premature end of file.
[xslt] Failed to process C:\apache-ant-1.10.1-bin\bin\Test.jtl
BUILD FAILED
C:\apache-ant-1.10.1-bin\bin\build.xml:124: Fatal error during transformation using C:\apache-ant-1.10.1-bin\bin\jmeter-results-report_21.xsl: Premature end of file.; SystemID: file:/C:/apache-ant-1.10.1-bin/bin/Test.jtl; Line#: 1; Column#: 1
Total time: 3 seconds
Actually, the correct answer is here. Just need to remove the comments from these lines:
<jvmarg value="-Xincgc"/>
<jvmarg value="-Xmx128m"/>
<jvmarg value="-Dproperty=value"/>
<jmeterarg value="-qextra.properties"/>
in the extracts\build.xml file.
Most likely your JMeter test is failing therefore it doesn't generate result file. I would suggest amending your target like
<jmeter
jmeterhome="${jmeter.home}"
testplan ="${testpath}/${test}.jmx"
resultlog="${testpath}/${test}.jtl"
jmeterlogfile="${testpath}/jmeter.log>
in build.xml file. The last line will "tell" the JMeter Ant task to generate jmeter.log file under the ${testpath}, you should be able to figure out what goes wrong by looking into this file.
References:
JMeter Ant Task Parameters
Five Ways To Launch a JMeter Test without Using the JMeter GUI
Adding to #Dmitri T answer jtl file is created only if you execute at least 1 Sample, so it won't be created in the following cases:
Your test plan failed and Stopped before executing Sampler
Your test doesn't contain Samplers
Your configuration is wrong and no thread were executed ( for example Thread number is 0)
You can try to execute/view/debug in GUI mode and check what's wrong.
use "resultlogdir" instead of "resultlog"
so change the build.xml like this:
<jmeter
jmeterhome="${jmeter.home}"
testplan ="${testpath}/${test}.jmx"
resultlogdir="${testpath}/log">
and also the "in" property in :
in="${testpath}/log/${test}.jtl"
I have no idea how to explain why, but it worked in my computer
When I tried to do merge using MergeResults plugin it throws error:
Error parsing field 'timeStamp' at line 1. java.text.ParseException: Unparseable date:"
TWO AggregateReport JTL files successfully converted into csv using the below CMD runner command
JMeterPluginsCMD.bat --generate-csv E:\JMETER\PROJECT_NGP\Results\SL_Rel\Build_165-20749\Reports_09-05-2017-17-07-07\NGP_LoadTest_Results_AgReport.csv --input-jtl E:\JMETER\PROJECT_NGP\Results\SL_Rel\Build_165-20749\Reports_09-05-2017-17-07-07\NGP_LoadTest_Results_AgReport.jtl --plugin-type AggregateReport
Below is the error log details from jmeter.log file
2017-09-06 12:35:40,963 INFO o.a.j.s.CSVSaveService: E:\JMETER\PROJECT_NGP\Results\SL_Rel\Build_165-20749\Reports_09-05-2017-17-07-07\NGP_LoadTest_Results_AgReport.csv does not appear to have a valid header. Using default configuration.
2017-09-06 12:35:40,963 WARN o.a.j.s.CSVSaveService: Error parsing field 'timeStamp' at line 1. java.text.ParseException: Unparseable date: "sampler_label,aggregate_report_count,average,aggregate_report_median,aggregate_report_90%_line,aggregate_report_95%_line,aggregate_report_99%_line,aggregate_report_min,aggregate_report_max,aggregate_report_error%,aggregate_report_rate,aggregate_report_bandwidth,aggregate_report_stddev"
2017-09-06 12:35:40,963 WARN o.a.j.r.ResultCollector: Problem reading JTL file: E:\JMETER\PROJECT_NGP\Results\SL_Rel\Build_165-20749\Reports_09-05-2017-17-07-07\NGP_LoadTest_Results_AgReport.csv
2017-09-06 12:35:40,963 WARN o.a.j.s.CSVSaveService: Unknown column name sampler_label,aggregate_report_count,average,aggregate_report_median,aggregate_report_90%_line,aggregate_report_95%_line,aggregate_report_99%_line,aggregate_report_min,aggregate_report_max,aggregate_report_error%,aggregate_report_rate,aggregate_report_bandwidth,aggregate_report_stddev
In user.properties file and properties file timestamp settings are same(see the below screenshots).
Not able to figured it out what was wrong, Please advise.
JMeter configuration on the machine where you are doing results merge must match configuration of the machine where tests were executed. If there are inconsistencies the majority of JMeter Listeners will fail, neither you will be able to generate HTML Reporting Dashboard
For example I see in your user.properties file the following issues:
You have duplicate jmeter.save.saveservice.timestamp_format property settings defining different timestamp formats
You have jmeter.save.saveservice.default_delimiter property set to \t while your results file is comma-separated
So you need to inspect JMeter's configuration of the machine where you are trying to merge results and make it inline with the machine where you ran the test.
References:
Configuring JMeter
Apache JMeter Properties Customization Guide
With the raw jtl files it's working as expected.
I just install neo4j 3.2.3 on my windows notebook and I try to load csv file.
LOAD CSV WITH HEADERS FROM 'file:///test.csv' AS line
WITH toUpper(line.TEST_NAME) AS TEST_NAME
CREATE(TEST);
I got the following error:
Neo.ClientError.Statement.ExternalResourceFailed: Couldn't load the external resource at: file:/C:/Users/*****/Documents/Neo4j/default.graphdb/import/test.csv
I cannot locate the neo4j.conf or propriety files in the default.graphdb directories.
can someone help?
I'm on windows 10 neo4j 3.2.3.
I can load from url. but with the same file format, I failed to load from local.
LOAD CSV FROM "https://gist.githubusercontent.com/jexp/d788e117129c3730a042/raw/a147631215456d86a77edc7ec08c128b9ef05e3b/people_leading_empty.csv"
AS line
WITH line LIMIT 4
RETURN line
successful
with the same file save as .../Neo4j/default.graphdb/import/test1.csv
LOAD CSV WITH HEADERS FROM "file:///test1.csv" AS line
WITH line LIMIT 4
RETURN line
I got error:
Neo.ClientError.Statement.ExternalResourceFailed: Couldn't load the external resource at: file:/C:/Users/....../Documents/Neo4j/default.graphdb/import/test.csv
From the error message, it can locate the file. But cannot perform the LOAD from local.
I cannot locate the neo4j.conf or propriety files in the
default.graphdb directories.
According to the Neo4j docs, the neo4j.conf file is located in the directory <neo4j-home>\conf\neo4j.conf for zip packages and %APPDATA%\Neo4j Community Edition\neo4j.conf for desktop installation.
You should locate the configuration file and set the following line.
dbms.security.allow_csv_import_from_file_urls=true
The LOAD CSV operation in Neo4j can only load the UTF-8 format files, try to change the import file's format to UTF-8(save the .csv file as .csv(utf-8) type).