Michael Martell created GEODE-4313:
--------------------------------------
Summary: Incorrect JVM Argument in gfsh
Key: GEODE-4313
URL: https://issues.apache.org/jira/browse/GEODE-4313
Project: Geode
Issue Type: Bug
Components: gfsh
Reporter: Michael Martell
When running the attached Powershell script to start a locator and server on
Windows, the output of the start server command is incorrent.
*{color:#14892c}Here's the script:{color}*
param(
[Parameter(HelpMessage="C# src directory")]
[string] $cssrc = "C:\gemfire-dotnetsession",
[Parameter(HelpMessage="Geode root directory")]
[string] $gfrootdir = "C:\gemfire"
)
$ErrorActionPreference = "Stop"
$IPADDRESS = "localhost"
$DIRGUID = "samplewebapps"
pushd $cssrc
echo "" "Killing java processes..." ""
Stop-Process -name java -ErrorAction Ignore
Remove-Item -Recurse -Force "c:\temp\*"
echo "" "Starting gemfire up..." ""
pushd ${gfrootdir}\bin
.\gfsh.bat `
-e "start locator --name=locator --http-service-port=0
--dir=C:/temp/${DIRGUID} --bind-address=${IPADDRESS}
--J=-Dgemfire.jmx-manager-hostname-for-clients=${IPADDRESS}
--J=-Dgeode.feature-protobuf-protocol=false
--enable-cluster-configuration=true" `
-e "configure pdx --read-serialized=true" `
-e "start server --name=gbp-server --log-level=error --dir=C:/temp/${DIRGUID}
--bind-address=${IPADDRESS} --J=-XX:+UseG1GC" `
-e "alter runtime --enable-statistics=true" `
-e "alter runtime --statistic-archive-file=Statistics.gfs" `
-e "create region --name=session --type=PARTITION" `
-e "deploy
--jar=${cssrc}\build\SessionStateStoreFunctions\SessionStateStoreFunctions.jar"
if (!$?) \{exit 1}
popd
{color:#d04437}*Here's the output (Note the error string highlighted in red
below, where the actual IP Address is concatenated with the loopback
IP):*{color}
S C:\gemfire-dotnetsession> C:\gemfire-dotnetsession\bin\RunLocalhostGemfire.ps1
Killing java processes...
Starting gemfire up...
(1) Executing - start locator --name=locator --http-service-port=0
--dir=C:/temp/samplewebapps --bind-address=localhost
--J=-Dgemfire.jmx-manager-hostname-for-clients=lo
calhost --J=-Dgeode.feature-protobuf-protocol=false
--enable-cluster-configuration=true
...
Locator in C:\temp\samplewebapps on 127.0.0.1[10334] as locator is currently
online.
Process ID: 19968
Uptime: 3 seconds
Geode Version: 9.1.1
Java Version: 1.8.0_131
Log File: C:\temp\samplewebapps\locator.log
JVM Arguments: -Dgemfire.http-service-port=0
-Dgemfire.enable-cluster-configuration=true
-Dgemfire.load-cluster-configuration-from-dir=false -Dgemfire.jmx-manager-hostna
me-for-clients=localhost -Dgeode.feature-protobuf-protocol=false
-Dgemfire.launcher.registerSignalHandlers=true -Djava.awt.headless=true
-Dsun.rmi.dgc.server.gcInterval=
9223372036854775806
Class-Path:
C:\gemfire\lib\geode-core-9.1.1.jar;C:\gemfire\lib\geode-dependencies.jar
Successfully connected to: JMX Manager [host=localhost, port=1099]
Cluster configuration service is up and running.
(2) Executing - configure pdx --read-serialized=true
persistent = false
read-serialized = true
ignore-unread-fields = false
(3) Executing - start server --name=gbp-server --log-level=error
--dir=C:/temp/samplewebapps --bind-address=localhost --J=-XX:+UseG1GC
....
Server in C:\temp\samplewebapps on 10.118.33.191[40404] as gbp-server is
currently online.
Process ID: 4376
Uptime: 4 seconds
Geode Version: 9.1.1
Java Version: 1.8.0_131
Log File: C:\temp\samplewebapps\gbp-server.log
JVM Arguments:
{color:#d04437}-Dgemfire.default.locators=10.118.33.191:127.0.0.1[10334]{color}
-Dgemfire.use-cluster-configuration=true -Dgemfire.bind-address=localhost
-Dgemfire.start-dev-re
st-api=false -Dgemfire.log-level=error -XX:+UseG1GC
-XX:OnOutOfMemoryError=taskkill /F /PID %p
-Dgemfire.launcher.registerSignalHandlers=true -Djava.awt.headless=true -D
sun.rmi.dgc.server.gcInterval=9223372036854775806
Class-Path:
C:\gemfire\lib\geode-core-9.1.1.jar;C:\gemfire\lib\geode-dependencies.jar
(4) Executing - alter runtime --enable-statistics=true
Runtime configuration altered successfully for the following member(s)
127.0.0.1(gbp-server:4376)<v1>:1025
(5) Executing - alter runtime --statistic-archive-file=Statistics.gfs
Runtime configuration altered successfully for the following member(s)
127.0.0.1(gbp-server:4376)<v1>:1025
(6) Executing - create region --name=session --type=PARTITION
Member | Status
---------- | -----------------------------------------
gbp-server | Region "/session" created on "gbp-server"
(7) Executing - deploy
--jar=C:\gemfire-dotnetsession\build\SessionStateStoreFunctions\SessionStateStoreFunctions.jar
Member | Deployed JAR | Deployed JAR Location
---------- | ------------------------------ |
------------------------------------------------------
gbp-server | SessionStateStoreFunctions.jar |
C:\temp\samplewebapps\SessionStateStoreFunctions.v1...
PS C:\gemfire-dotnetsession>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)