Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question
0

gs.bat unable to execute java command

Hi,

I am trying to execute gigaspaces 9.7.1-ga-b10800 gs-agent.bat (that in turn calls gs.bat) with java 1.7.0_55-b13. With echo-ing I traced the issue at the line

%COMMAND%

from gs.bat.
Am I missing something? Is there a place I can check if some versions of gigaspaces and java are compatible?
The java version 1.6 works fine with this version of gigaspaces.
I read this:

Please note that from version 8.0 onwards, GigaSpaces XAP will no longer support the Java 1.5 SDK, and will require the use of Java 1.6 SDK or higher. For details about Java 1.4 & 1.5 SDK EOL, please refer to the following page:http://java.sun.com/products/archive/eol.policy.html

But it doesn't say anything about java 7 and gigaspaces 9.7.1.

The exact command is ([SOME...] represent some other string):

"C:\Program Files\Java\jdk1.7.0_55\bin\java"  -server -XX:+AggressiveOpts -showversion -XX:MaxPermSize=256m -XX:+HeapDumpOnOutOfMemoryError -Xmx512m -Dcom.sun.jini.reggie.initialUnicastDiscoveryPort=4169 -Dcom.gs.deploy=[SOME-PATH-TO-GS-HOME]/deploy -DagentId= -DgsaServiceID= -DenableDynamicLocators= -Xbootclasspath/p:"[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\\lib\platform\xml\*" -cp ;"[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\";"[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\\lib\platform\sigar\*;";"[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\\lib\platform\boot\gs-boot.jar"; -Dsun.rmi.dgc.client.gcInterval=36000000 -Dsun.rmi.dgc.server.gcInterval=36000000 -Djava.rmi.server.hostname=""[SOMETHING]"" -Djava.rmi.server.RMIClassLoaderSpi=default -Djava.rmi.server.logCalls=false -Dcom.gs.jini_lus.locators=null -Dcom.gs.jini_lus.groups=[SOMETHING] -Dcom.gs.logging.debug=false -Djava.util.logging.config.file="[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\/config/gs_logging.properties" com.gigaspaces.start.SystemBoot com.gigaspaces.start.services=\"GSA\" gsa.gsc 0 gsa.global.gsm 0 gsa.lus 1

The output renders the following:

java version "1.7.0_55" Java(TM) SE
Runtime Environment (build 1.7.0_55-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.55-b03, mixed mode)

Usage: java [-options] class [args...]
(to execute a class) or java [-options] -jar jarfile [args...]
(to execute a jar file)

where options include:
-d32 use a 32-bit data model if available
e.t.c

Best regards,
despot

UPDATE:
I transferred JAVA_HOME to "C:\Java\jdk1.7.0_55". I also tried the newest java jdk1.7.0_71, but no success for the above command.
Success though for:
C:\Java\jdk1.7.0_71
gs-agent.bat gsa.global.esm 1 gsa.gsc 2 gsa.global.lus 2 gsa.global.gsm 2
and
C:\Java\jdk1.7.0_71
gs-agent.bat gsa.gsc 0 gsa.global.gsm 0 gsa.lus 1
This leads me to believe that the arguments sent to the java virtual machine (java.exe command) are not proper in some way. I already tried deleting part of the arguments like:
1) -DagentId= -DgsaServiceID= -DenableDynamicLocators=
2) -XX:+AggressiveOpts -XX:MaxPermSize=256m -XX:+HeapDumpOnOutOfMemoryError
3) without 1) and 2)
with no success.

asked 2015-01-15 11:24:59 -0500

Despot gravatar image

updated 2015-01-20 07:31:18 -0500

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
1

Can you please move jdk1.7.0_55 to c:\ or C:\Java

Please don't have it installed under C:\Program Files

answered 2015-01-16 12:00:09 -0500

shay hassidim gravatar image
edit flag offensive delete link more

Comments

Hi Shay,

I transferred JAVA_HOME to "C:\Java\jdk1.7.0_55". I also tried the newest java jdk1.7.0_71, but no success for the above command.

Success though for:
C:\Java\jdk1.7.0_71
gs-agent.bat gsa.global.esm 1 gsa.gsc 2 gsa.global.lus 2 gsa.global.gsm 2

and

C:\Java\jdk1.7.0_71
gs-agent.bat gsa.gsc 0 gsa.global.gsm 0 gsa.lus 1

This leads me to believe that the arguments sent to the java virtual machine (java.exe command) are not proper in some way. I already tried deleting part of the arguments like:
1) -DagentId= -DgsaServiceID= -DenableDynamicLocators=
2) -XX:+AggressiveOpts -XX:MaxPermSize=256m -XX:+HeapDumpOnOutOfMemoryError
3) without 1) and 2)
with no success.

Despot gravatar imageDespot ( 2015-01-20 06:28:15 -0500 )edit
0

What changes did you made to setenv? and gs? please try vanila installation and just change java home"set JAVA_HOME=C:\Java\jdk1.7.0_55.I did the same and didn't face any issues.

answered 2015-01-20 06:55:57 -0500

Ester gravatar image
edit flag offensive delete link more

Comments

please see update

Despot gravatar imageDespot ( 2015-01-20 07:30:22 -0500 )edit
0

For some reason java 7 doesn't like this path:

\tools\groovy\bin\..\..\..\

when investigating further I found out that JSHOMEDIR is being set to

[SOME-PATH-TO-GS-HOME]\tools\groovy\bin\..\..\..\

so in setenv.bat, I placed a

set JSHOMEDIR=%~dp0\..

before the line:

if "%JSHOMEDIR%" == "" set JSHOMEDIR=%~dp0\..

For some reason setting an (system/user) environment variable didn't change the value of JSHOMEDIR (and yes, I restarted the cmd).

Cheers!

answered 2015-01-21 07:54:50 -0500

Despot gravatar image
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2015-01-15 09:26:34 -0500

Seen: 569 times

Last updated: Jan 21 '15