You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@jmeter.apache.org by bu...@apache.org on 2013/07/13 17:48:04 UTC
[Bug 55260] New: Launch script fails under cygwin - suggested
(simple) tweak provided
https://issues.apache.org/bugzilla/show_bug.cgi?id=55260
Bug ID: 55260
Summary: Launch script fails under cygwin - suggested (simple)
tweak provided
Product: JMeter
Version: 2.9
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: Main
Assignee: issues@jmeter.apache.org
Reporter: charles.butterfield@nextcentury.com
When running under cygwin, the launch script "bin/jmeter" doesn't quite work
properly. The problem is that the jar file path passed to Java is a cygwin
style path and needs to be converted to a windows style path (since java is a
native windows application).
I included a simple fix below, butof course there are many ways to accomplish
the same thing, not sure what your preferred conventions are. One could also
use a similar OS test to include the MAC specific tweaks in one common *nix
launch script.
I did notice that invoking jmeter.bat seemed to properly launch, but I am loath
to change ALL of our testing scripts that launch jmeter in different was
depending on which *nix platform I'm running on. I found it easier to just
tweak the primordal jmeter script. I presume others would also benefit the
same way
Best regards
-- Charlie
P.S. Would it be useful to add CYGWIN as an OS-type for the bug reports?
One possible patch:
$ diff -c jmeter ORIG/
*** jmeter 2013-07-13 11:31:47.145846700 -0400
--- ORIG/jmeter 2013-07-13 11:45:32.882489700 -0400
***************
*** 87,97 ****
ARGS="$SERVER $DUMP $HEAP $NEW $SURVIVOR $TENURING $EVACUATION $RMIGC $PERM"
! #java $ARGS $JVM_ARGS -jar "`dirname "$0"`/ApacheJMeter.jar" "$@"
! # If running under cygwin, convert the jar path to windows format
! if uname | grep -i --quiet 'cygwin' ; then
! jarpath=$(cygpath -w "`dirname "$0"`/ApacheJMeter.jar")
! java $ARGS $JVM_ARGS -jar "$jarpath" "$@"
! else
! java $ARGS $JVM_ARGS -jar "`dirname "$0"`/ApacheJMeter.jar" "$@"
! fi
--- 87,90 ----
ARGS="$SERVER $DUMP $HEAP $NEW $SURVIVOR $TENURING $EVACUATION $RMIGC $PERM"
! java $ARGS $JVM_ARGS -jar "`dirname "$0"`/ApacheJMeter.jar" "$@"
--
You are receiving this mail because:
You are the assignee for the bug.