jmeter-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 62107] jmeter.bat fails to execute due to space in the (program files) for jdk path
Date Fri, 16 Feb 2018 04:32:20 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=62107

--- Comment #4 from Manu <manu2k@gmail.com> ---
c:\apache-jmeter-3.2\bin>jmeter.bat

c:\apache-jmeter-3.2\bin>rem   Licensed to the Apache Software Foundation (ASF)
under one or more

c:\apache-jmeter-3.2\bin>rem   contributor license agreements.  See the NOTICE
file distributed with

c:\apache-jmeter-3.2\bin>rem   this work for additional information regarding
copyright ownership.

c:\apache-jmeter-3.2\bin>rem   The ASF licenses this file to You under the
Apache License, Version 2.0

c:\apache-jmeter-3.2\bin>rem   (the "License"); you may not use this file
except in compliance with

c:\apache-jmeter-3.2\bin>rem   the License.  You may obtain a copy of the
License at

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem       http://www.apache.org/licenses/LICENSE-2.0

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   Unless required by applicable law or agreed to
in writing, software

c:\apache-jmeter-3.2\bin>rem   distributed under the License is distributed on
an "AS IS" BASIS,

c:\apache-jmeter-3.2\bin>rem   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
either express or implied.

c:\apache-jmeter-3.2\bin>rem   See the License for the specific language
governing permissions and

c:\apache-jmeter-3.2\bin>rem   limitations under the License.

c:\apache-jmeter-3.2\bin>rem  
=====================================================

c:\apache-jmeter-3.2\bin>rem   Environment variables that can be defined
externally:

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   Do not set the variables in this script. Instead
put them into a script

c:\apache-jmeter-3.2\bin>rem   setenv.bat in JMETER_HOME/bin to keep your
customizations separate.

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   DDRAW       - (Optional) JVM options to
influence usage of direct draw,

c:\apache-jmeter-3.2\bin>rem                 e.g. '-Dsun.java2d.ddscale=true'

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JMETER_BIN  - JMeter bin directory (must end in
\)

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JMETER_COMPLETE_ARGS - if set indicates that
JVM_ARGS is to be used exclusively instead

c:\apache-jmeter-3.2\bin>rem                 of adding other options like HEAP
or GC_ALGO

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JMETER_HOME - installation directory. Will be
guessed from location of jmeter.bat

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JM_LAUNCH   - java.exe (default) or javaw.exe

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JM_START    - set this to "start" to launch
JMeter in a separate window

c:\apache-jmeter-3.2\bin>rem                 this is used by the jmeterw.cmd
script.

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   JVM_ARGS    - (Optional) Java options used when
starting JMeter, e.g. -Dprop=val

c:\apache-jmeter-3.2\bin>rem                 Defaults to '-Duser.language="en"
-Duser.region="EN"'

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   GC_ALGO     - (Optional) JVM garbage collector
options

c:\apache-jmeter-3.2\bin>rem                 Defaults to '-XX:+UseG1GC
-XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20'

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem   HEAP        - (Optional) JVM memory settings
used when starting JMeter

c:\apache-jmeter-3.2\bin>rem                 Defaults to '-Xms1g -Xmx1g
-XX:MaxMetaspaceSize=256m'

c:\apache-jmeter-3.2\bin>rem

c:\apache-jmeter-3.2\bin>rem  
=====================================================

c:\apache-jmeter-3.2\bin>setlocal

c:\apache-jmeter-3.2\bin>rem Guess JMETER_HOME if not defined

c:\apache-jmeter-3.2\bin>set "CURRENT_DIR=c:\apache-jmeter-3.2\bin"

c:\apache-jmeter-3.2\bin>if not "" == "" goto gotHome

c:\apache-jmeter-3.2\bin>set "JMETER_HOME=c:\apache-jmeter-3.2\bin"

c:\apache-jmeter-3.2\bin>if exist "c:\apache-jmeter-3.2\bin\bin\jmeter.bat"
goto okHome

c:\apache-jmeter-3.2\bin>cd ..

c:\apache-jmeter-3.2>set "JMETER_HOME=c:\apache-jmeter-3.2"

c:\apache-jmeter-3.2>cd "c:\apache-jmeter-3.2\bin"

c:\apache-jmeter-3.2\bin>if exist "c:\apache-jmeter-3.2\bin\jmeter.bat" goto
okHome

c:\apache-jmeter-3.2\bin>rem Get standard environment variables

c:\apache-jmeter-3.2\bin>if exist "c:\apache-jmeter-3.2\bin\setenv.bat" call
"c:\apache-jmeter-3.2\bin\setenv.bat"

c:\apache-jmeter-3.2\bin>if not defined JMETER_LANGUAGE (
rem Set language
 rem Default to en_EN
 set JMETER_LANGUAGE=-Duser.language="en" -Duser.region="EN"
)

c:\apache-jmeter-3.2\bin>rem Minimal version to run JMeter

c:\apache-jmeter-3.2\bin>set MINIMAL_VERSION=1.8.0

c:\apache-jmeter-3.2\bin>rem --add-modules java.activation if JAVA 9

c:\apache-jmeter-3.2\bin>set JAVA9_OPTS=

c:\apache-jmeter-3.2\bin>for /F "tokens=3" %g in ('java -version 2>&1 | findstr
/i "version"') do (
rem @echo Debug Output: %g
 set JAVAVER=%g
)

c:\apache-jmeter-3.2\bin>(
rem @echo Debug Output: "1.8.0_162"
 set JAVAVER="1.8.0_162"
)

c:\apache-jmeter-3.2\bin>if not defined JAVAVER (

 set ERRORLEVEL=2
 goto pause
)

c:\apache-jmeter-3.2\bin>rem Check if version is from OpenJDK or Oracle Hotspot
JVM prior to 9 containing 1.${version}.x

c:\apache-jmeter-3.2\bin>rem JAVAVER will be equal to "9.0.4" (quotes are part
of the value) for Oracle Java 9

c:\apache-jmeter-3.2\bin>rem JAVAVER will be equal to "1.8.0_161" (quotes are
part of the value) for Oracle Java 8

c:\apache-jmeter-3.2\bin>rem so we extract 2 chars starting from index 1

c:\apache-jmeter-3.2\bin>IF "1." == "1." (
set JAVAVER=1.8.0_162
 for /F "delims=. tokens=1-3" %v in (""1.8.0_162"") do (set current_minor=%w )
)  else (
rem Java 9 at least
 set current_minor=9
 set JAVA9_OPTS=--add-modules java.activation --add-opens
java.desktop/sun.awt=ALL-UNNAMED --add-opens java.desktop/sun.swing=ALL-UNNAMED
--add-opens java.desktop/javax.swing.text.html=ALL-UNNAMED --add-opens
java.desktop/java.awt=ALL-UNNAMED --add-opens
java.desktop/java.awt.font=ALL-UNNAMED
--add-opens=java.base/java.lang=ALL-UNNAMED
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED
--add-opens=java.base/java.lang.reflect=ALL-UNNAMED
--add-opens=java.base/java.util=ALL-UNNAMED
--add-opens=java.base/java.text=ALL-UNNAMED
)

c:\apache-jmeter-3.2\bin>(set current_minor=8 )

c:\apache-jmeter-3.2\bin>for /F "delims=. tokens=1-3" %v in ("1.8.0") do (set
minimal_minor=%w )

c:\apache-jmeter-3.2\bin>(set minimal_minor=8 )

c:\apache-jmeter-3.2\bin>if not defined current_minor (

 set ERRORLEVEL=2
 goto pause
)

c:\apache-jmeter-3.2\bin>rem @echo Debug: CURRENT=8 - MINIMAL=8

c:\apache-jmeter-3.2\bin>if 8 LSS 8 (

 set ERRORLEVEL=3
 goto pause
)

c:\apache-jmeter-3.2\bin>if not defined JM_LAUNCH (set JM_LAUNCH=java.exe )

c:\apache-jmeter-3.2\bin>if exist jmeter.bat goto winNT1

c:\apache-jmeter-3.2\bin>rem On NT/2K grab all arguments at once

c:\apache-jmeter-3.2\bin>set JMETER_CMD_LINE_ARGS=

c:\apache-jmeter-3.2\bin>rem The following link describes the -XX options:

c:\apache-jmeter-3.2\bin>rem
http://docs.oracle.com/javase/8/docs/technotes/tools/unix/java.html

c:\apache-jmeter-3.2\bin>if not defined HEAP (
rem See the unix startup file for the rationale of the following parameters,
 rem including some tuning recommendations
 set HEAP=-Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m
)

c:\apache-jmeter-3.2\bin>rem Uncomment this to generate GC verbose file with
Java prior to 9

c:\apache-jmeter-3.2\bin>rem set VERBOSE_GC=-verbose:gc
-Xloggc:gc_jmeter_%p.log -XX:+PrintGCDetails -XX:+PrintGCCause
-XX:+PrintTenuringDistribution -XX:+PrintHeapAtGC
-XX:+PrintGCApplicationConcurrentTime -XX:+PrintGCApplicationStoppedTime
-XX:+PrintGCDateStamps -XX:+PrintAdaptiveSizePolicy

c:\apache-jmeter-3.2\bin>rem Uncomment this to generate GC verbose file with
Java 9 and above

c:\apache-jmeter-3.2\bin>rem set
VERBOSE_GC=-Xlog:gc*,gc+age=trace,gc+heap=debug:file=gc_jmeter_%p.log

c:\apache-jmeter-3.2\bin>rem You may want to add those settings

c:\apache-jmeter-3.2\bin>rem -XX:+ParallelRefProcEnabled
-XX:+PerfDisableSharedMem

c:\apache-jmeter-3.2\bin>if not defined GC_ALGO (set GC_ALGO=-XX:+UseG1GC
-XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20 )

c:\apache-jmeter-3.2\bin>set SYSTEM_PROPS=-Djava.security.egd=file:/dev/urandom

c:\apache-jmeter-3.2\bin>rem Always dump on OOM (does not cost anything unless
triggered)

c:\apache-jmeter-3.2\bin>set DUMP=-XX:+HeapDumpOnOutOfMemoryError

c:\apache-jmeter-3.2\bin>rem Uncomment this if you run JMeter in DOCKER (need
Java SE 8u131 or JDK 9)

c:\apache-jmeter-3.2\bin>rem see
https://blogs.oracle.com/java-platform-group/java-se-support-for-docker-cpu-and-memory-limits

c:\apache-jmeter-3.2\bin>rem set RUN_IN_DOCKER=-XX:+UnlockExperimentalVMOptions
-XX:+UseCGroupMemoryLimitForHeap

c:\apache-jmeter-3.2\bin>rem Additional settings that might help improve GUI
performance on some platforms

c:\apache-jmeter-3.2\bin>rem See:
http://www.oracle.com/technetwork/java/perf-graphics-135933.html

c:\apache-jmeter-3.2\bin>if not defined DDRAW (
set DDRAW=
 rem  Setting this flag to true turns off DirectDraw usage, which sometimes
helps to get rid of a lot of rendering problems on Win32.
 rem set DDRAW= -Dsun.java2d.noddraw=true
 rem  Setting this flag to false turns off DirectDraw offscreen surfaces
acceleration by forcing all createVolatileImage calls to become createImage
calls, and disables hidden acceleration performed on surfaces created with
createImage .
 rem set DDRAW= -Dsun.java2d.ddoffscreen=false
 rem Setting this flag to true enables hardware-accelerated scaling.
 rem set DDRAW= -Dsun.java2d.ddscale=true
)

c:\apache-jmeter-3.2\bin>rem Collect the settings defined above

c:\apache-jmeter-3.2\bin>if not defined JMETER_COMPLETE_ARGS (set ARGS=
-XX:+HeapDumpOnOutOfMemoryError -Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m 
-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20 
-Djava.security.egd=file:/dev/urandom -Duser.language="en" -Duser.region="EN" 
)  else (set ARGS= )

c:\apache-jmeter-3.2\bin>C:\Program Files\Java\jdk1.8.0_162\bin\ 
-XX:+HeapDumpOnOutOfMemoryError -Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m 
-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20 
-Djava.security.egd=file:/dev/urandom -Duser.language="en" -Duser.region="EN"  
-jar "C:\apache-jmeter-3.2\bin\ApacheJMeter.jar"
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.

c:\apache-jmeter-3.2\bin>rem If the errorlevel is not zero, then display it and
pause

c:\apache-jmeter-3.2\bin>if NOT errorlevel 0 goto pause

c:\apache-jmeter-3.2\bin>if errorlevel 1 goto pause

c:\apache-jmeter-3.2\bin>echo errorlevel=9009
errorlevel=9009

c:\apache-jmeter-3.2\bin>pause
Press any key to continue . . .

-- 
You are receiving this mail because:
You are the assignee for the bug.
Mime
View raw message