I can get JMeter to run in non GUI mode but it stops after just running just one iteration. How do I get it to run continuously ? Loop Count is set to Infinite in this 5.5 JMeter version.
jmeter -n -t SocialGeneratorTrafficMOCKSQS.jmx -l C:\installs\How2Run_JMeter5_5_cmd_line\Results.csv -e -o C:\installs\How2Run_JMeter5_5_cmd_line\Report.csv
thank you
The reason for stopping the thread can be found in jmeter.log file
I can think of 2 possible reasons which might cause premature ending of your test:
CSV Data Set Config is configured to stop thread on EOF, make sure it's set up like at the image below:
Flow Control Action sampler is configured to stop either thread or test
Related
I have used 100 users for my testing and it is completed 100 and it shows as 100/100 in the right-hand upper corner, but the timer is working? I don't know why is that..can you please explain to me why it happens like that. because when am using 5 users and once it completed timer is stopped. please help me. please check the attachment.
There is no any attachment however I can try to guess the possible reason.
When you start JMeter the following beautiful warning is displayed:
================================================================================
Don't use GUI mode for load testing !, only for Test creation and Test debugging.
For load testing, use CLI Mode (was NON GUI):
jmeter -n -t [jmx file] -l [results file] -e -o [Path to web report folder]
& increase Java Heap to meet your test requirements:
Modify current env variable HEAP="-Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m" in the jmeter batch file
Check : https://jmeter.apache.org/usermanual/best-practices.html
================================================================================
So my expectation is that 100 users is way too much than JMeter GUI can handle so consider running your JMeter test in command-line non-GUI mode and it should end normally/gracefully. If it doesn't - make sure to follow JMeter Best Practices
I am new to flink and reading Flink 1.8 source code(https://github.com/apache/flink/tree/release-1.8) to understand how flink works with YARN.
I know there are detached mode and non-detached mode for the per-job cluster mode.
For the non-detached mode, such as the following command:
flink run -m yarn-cluster -c my.HelloFlink -yn 2 -ys 1 ./my.jar
After the yarn cluster is deployed,then the client process starts to run my main method(my.HelloFlink#main), and the client process doesn't terminate until my main method finished.
For the detached mode, such as the following command:
flink run -d -m yarn-cluster -c my.HelloFlink -yn 2 -ys 1 ./my.jar
After the yarn cluster is deployed,then the client process terminates soon, but I didn't find where(in which process) my main method gets to run(my.HelloFlink#main), could some one help me out here and help on where my main method runs?
Thanks, I have struggled on this question for days, thanks very much!
When you use flink run ... you are running a bash script which ends with this line
exec $JAVA_RUN $JVM_ARGS $FLINK_ENV_JAVA_OPTS "${log_setting[#]}" -classpath "`manglePathList "$CC_CLASSPATH:$INTERNAL_HADOOP_CLASSPATHS"`" org.apache.flink.client.cli.CliFrontend "$#"
which fires up a JVM running the CliFrontend. Your main method runs there. What your main method does is to construct a job graph and submit it to the yarn cluster, along with its dependencies. If you run in detached mode, this CliFrontend process simply exits after submitting the job, as it is no longer useful.
By the way, Flink 1.11 has added a new flink run-application deployment target that runs the main method in the Job Manager instead. This has significant advantages in some situations; see Application Deployment in Flink: Current State and the new Application Mode for details.
I want to build a system with applications on another partition, an app-filessystem. All binaries, configs and service files which belong to the application should be in the app-fs.
I'm using the following versions: kernel 4.9.x, systemd v234.
The app-partition is mounted at /opt, this includes following files:
/opt/usr/bin/app-binary
/opt/etc/systemd/system/multiuser.target/link_2_app.service
/opt/lib/systemd/system/app.service
Here is the service file:
[Unit]
Description=The application description.
After=syslog.target basic.target
[Service]
ExecStart=/opt/usr/bin/app-binary
Type=simple
[Install]
WantedBy=multi-user.target
To synchronize the files with rootfilesystem I created 2 overlays, this could be the /etc/fstab entries (sorry for format, one line didn't work):
/dev/app-partition /opt auto defaults,x-systemd.mount 0 2
overlay /etc overlay defaults,x-systemd.mount, x-systemd.after=opt.mount,lowerdir=/etc,upperdir=/opt/etc,workdir=/work/etc 0 2
overlay /lib/systemd/system overlay defaults,x-systemd.mount,x-systemd.after=opt.mount,lowerdir=/lib/systemd/system,upperdir=/opt/lib/systemd/system,workdir=/work/lib 0 2
This is handled before local-fs.target is reached.
Result
I can start the app successfully but manually with systemctl start app.service. The status with "systemctl status app.service" says it is enabled. But the app is not starting at boot time. Systemd does not give a message about trying to start the app.
Questions
Is there a way to debug this behaviour? When does systemd check the service files? Is there a way to trigger it again? Are there other ways to handle this use case with systemd?
systemd is checking the unit files once at start, an init script which is creating the overlayFS before systemd startup can handle this use case.
Another idea (but not tested) would be: systemctl daemon-reload
systemctl daemon-reload
I test this not work.
In my situation . I use systemd-networkd,and I overlay
For disabling autostart of services seems using
ConditionPathIsSymbolicLink=#OVERLAY_UPPER_LAYER#/etc/systemd/system/../XX.service
as additional condition in service drop-in works
I'm using latest JMeter 3.3 to run a latest Selenium WebDriver test, everything seems to be OK,
I only have 1 thread configured with 1 sec ramp up and 1 loop count, however after the webdriver execution is completed, JMeter does not stops the overall test execution and keeps on executing the test for infinity, I'm not sure why is that happening, I'm using chromedriver and all the configuration I have done is as per jmeter documentation, I have also added WDS.sampleResult.sampleEnd() command at the end of my script. Please refer screenshots attached -
Thread Group -
I just want as soon as my sample ends, JMeter test execution should also stop.
There is a problem in your configuration as per the bug report you made:
https://bz.apache.org/bugzilla/show_bug.cgi?id=61661
You have the below exception occurring which is due to missing jar that contains:
com/sun/jna/platform/win32/Kernel32
So download it with it dependencies put it in jmeter/lib folder.
You can find it here:
http://www.java2s.com/Code/Jar/j/Downloadjna330platformjar.htm
http://www.java2s.com/Code/Jar/j/Downloadjna330jar.htm
I've created a JMeter script that I should run later on Jenkins.
First in my script I add a Thread Group with 1 user, 1 loop and a Beanshell Sampler to start the ServerAgent to later get PerfMon metrics from the server.
In Beanshell Sampler I have added:
Runtime.getRuntime().exec("C:/Windows/System32/cmd.exe /c D:/AppServer/AppServer.bat");
Inside the batch file (AppServer.bat) I have the following:
plink -v -ssh <username>#<host> -pw <password> -m D:\AppServer\commands.sh > D:\AppServer\outputlog.txt
and in commands.sh file I have:
#!/bin/bash
cd /ServerAgent-2.2.1
./startAgent.sh --udp-port 0 --sysinfo --auto-shutdown
In the second Tread Group (multiple users and loop forever for 10 min) is the recorded test steps and in the third Tread Group (1 user, 1 loop) I have only PerfMon listener.
Problem
When I'm running the test seams like all Threads are starting at the same time and there is not enough time to connect to the server and so the PerfMon metrics will not display (Connection refused: connect).
What I've tried
I tried with timers, setUp Thread Group and setting delay on second and third thread groups but I wasn't able to find a solution. The bat file is working. I tested it with disabling the other tread groups and I'm getting connected successfully to the server.
Also tried a different approach. I split the first tread group into one .jmx test and the other two Thread Groups into other test. In Jenkins I'm having two Build Steps.
In the first Build step I have Execute Windows Batch Command:
jmeter -n -t D:/SearchOrder/AppServerStart.jmx
Then I've add another Build Step in Jenkins to Invoke Ant build file to start the test script with the PerfMon.
The Console Output:
...
Executing test plan: D:\SearchOrder\AppServerStart.jmx ==> D:\SearchOrder\OrderSearch.jtl
Created the tree successfully using D:\SearchOrder\AppServerStart.jmx
Starting the test # Wed Dec 03 04:52:25 PST 2014 (1417611145595)
Waiting for possible shutdown message on port 4445
Tidying up ... # Wed Dec 03 04:52:25 PST 2014 (1417611145847)
... end of run
Executing test plan: D:\SearchOrder\OrderSearch.jmx ==> D:\SearchOrder\OrderSearch.jtl
Created the tree successfully using D:\SearchOrder\OrderSearch.jmx
Starting the test # Wed Dec 03 04:52:27 PST 2014 (1417611147067)
Waiting for possible shutdown message on port 4445_
...
The build are starting one after another and the server is not started in those 2 seconds, from one to another build steps.
Does anyone have similar experience or some advice on how to resolve this?
Are you sure you can connect to the serveragent.
Try
telnet localhost <portNumber>
A successful connection can be checked by keying in test, the response should be Yep. Or by querying for metrics
metrics:cpu
should look something like
13.451776649746192
11.688311688311689
12.071156289707751
16.64564943253468