removing those quotes works for me too (Windows 7)
Ian
On 30 March 2016 at 15:09, Chris Snider <[email protected]> wrote:
> I can corroborate the findings using the startup.bat with a fresh download
> from the link Ben provided.
>
>
>
> Welcome to GeoServer!
>
>
>
> JAVA_HOME: c:\Program Files\Java\jdk1.8.0_74
>
>
>
> The GEOSERVER_HOME environment variable is not defined.
>
> Temporarily setting GEOSERVER_HOME to the following directory:
>
> F:\geoserver-2.9-SNAPSHOT
>
>
>
> The GEOSERVER_DATA_DIR environment variable is not defined correctly.
>
> Temporarily setting GEOSERVER_DATA_DIR to the following directory:
>
> F:\geoserver-2.9-SNAPSHOT\data_dir
>
>
>
> Please wait while loading GeoServer...
>
>
>
> Error: Could not find or load main class
>
>
>
> Press any key to continue . . .
>
>
>
>
>
> java -version
>
> java version "1.8.0_74"
>
> Java(TM) SE Runtime Environment (build 1.8.0_74-b02)
>
> Java HotSpot(TM) 64-Bit Server VM (build 25.74-b02, mixed mode)
>
>
>
>
>
> Changing the startup line in the :run block to the following (dropping the
> quotes around the JAVA_OPTS) as Jukka suggested
>
> "%RUN_JAVA%" %JAVA_OPTS% -DGEOSERVER_DATA_DIR="%GEOSERVER_DATA_DIR%"
> -Djava.awt.headless=true -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar
>
>
>
> Works.
>
>
>
> My ultimate command line:
>
> "c:\Program Files\Java\jdk1.8.0_74\bin\java"
> -DGEOSERVER_DATA_DIR="F:\geoserver-2.9-SNAPSHOT\data_dir"
> -Djava.awt.headless=true -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar
>
>
>
> Starts
>
>
>
> Adding a static JAVA_OPTS before starting
>
> F:\geoserver-2.9-SNAPSHOT\bin>set JAVA_OPTS=-Xmx4096m -Xms4096m
>
> F:\geoserver-2.9-SNAPSHOT\bin>startup.bat
>
>
>
> Starts
>
>
>
> Generated command:
>
> "c:\Program Files\Java\jdk1.8.0_74\bin\java" -Xmx4096m -Xms4096m
> -DGEOSERVER_DATA_DIR="F:\geoserver-2.9-SNAPSHOT\data_dir"
> -Djava.awt.headless=true -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar
>
>
>
>
>
> Chris Snider
>
> Senior Software Engineer
>
> *Intelligent Software Solutions, Inc.*
>
> [image: Description: Description: Description:
> cid:[email protected]]
>
>
>
> *From:* Rahkonen Jukka (MML) [mailto:[email protected]]
> *Sent:* Wednesday, March 30, 2016 7:51 AM
> *To:* [email protected]
> *Subject:* Re: [Geoserver-devel] Can't start geoserver-2.9-SNAPSHOT on
> Windows
>
>
>
> Hi,
>
>
>
> This IS a valid java path for me
>
> *RUN_JAVA=C:\ProgramData\Oracle\Java\javapath\java.exe*
>
>
>
> So it seems that the only fix that is needed is to remove the empty
> JAVA_OPTS variable. I made some mess with copy-paste in the last mail so
> I’ll add the line that works for me here:
>
>
>
> "%RUN_JAVA%" -DGEOSERVER_DATA_DIR="%GEOSERVER_DATA_DIR%"
> -Djava.awt.headless=true -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar
>
>
>
> -Jukka-
>
>
>
>
>
> *Lähettäjä:* Rahkonen Jukka (MML) [
> mailto:[email protected]
> <[email protected]>]
> *Lähetetty:* 30. maaliskuuta 2016 16:38
> *Vastaanottaja:* Ian Turton; Ben Caradoc-Davies
> *Kopio:* [email protected]
> *Aihe:* Re: [Geoserver-devel] Can't start geoserver-2.9-SNAPSHOT on
> Windows
>
>
>
> Hi,
>
>
>
> There are probably two issues which prevent the launch command to work:
>
>
>
> "%RUN_JAVA%" "%RUN_JAVA%" "%JAVA_OPTS%"
> -DGEOSERVER_DATA_DIR="%GEOSERVER_DATA_DIR%" -Djava.awt.headless=true
> -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar-DGEOSERVER_DATA_DIR="%GEOSERVER_DATA_DIR%"
> -Djava.awt.headless=true -DSTOP.PORT=8079 -DSTOP.KEY=geoserver -jar
> start.jar
>
>
>
> The first one is that environment variable JAVA_OPTS is empty at this
> stage. Removing "%JAVA_OPTS%" makes Geoserver to start but there can be
> another issue with RUN_JAVA environment.
>
>
>
> If there is a valid JAVA_HOME set on the computer before running
> startup.bat everything is probably going well. However, for me JAVA_HOME is
> empty before I start to run the startup.bat and when the batch goes so far
> as trying to start java it is set to this peculiar value:
>
>
>
> *RUN_JAVA=C:\ProgramData\Oracle\Java\javapath\java.exe*
>
>
>
> So two places to look at:
>
> 1) Empty JAVA_OPTS is bad
>
> 2) This block in the batch file may set a surprising value for the
> RUN_JAVA
>
>
>
> :trySystemJava
>
> for /f %%i in ('where java') do set RUN_JAVA=%%i
>
> rem --- we might be on amd64 having only x86 jre installed ---
>
> if "%RUN_JAVA%"=="" if DEFINED ProgramFiles(x86) if NOT
> "%PROCESSOR_ARCHITECTURE%"=="x86" (
>
> rem --- restart the batch in x86 mode---
>
> echo Warning: No java interpreter found in path.
>
> echo Retry using Wow64 filesystem [32bit environment] redirection.
>
> %SystemRoot%\SysWOW64\cmd.exe /c %0 %*
>
> exit /b %ERRORLEVEL%
>
> )
>
> if "RUN_JAVA%"=="" goto noJava
>
> goto checkGeoServerHome
>
>
>
> -Jukka Rahkonen-
>
>
>
>
>
> *Lähettäjä:* Ian Turton [mailto:[email protected] <[email protected]>]
> *Lähetetty:* 30. maaliskuuta 2016 16:23
> *Vastaanottaja:* Ben Caradoc-Davies
> *Kopio:* Rahkonen Jukka (MML); [email protected]
> *Aihe:* Re: [Geoserver-devel] Can't start geoserver-2.9-SNAPSHOT on
> Windows
>
>
>
> I can confirm this behaviour with today's master. It will start when you
> run it from the command line but fails when you double click start.bat or
> run from the command line
>
>
>
> The console says:
>
>
>
> Welcome to GeoServer!
>
>
>
> The GEOSERVER_HOME environment variable is not defined.
>
> Temporarily setting GEOSERVER_HOME to the following directory:
>
> C:\Users\astun\Desktop\geoserver-2.9-SNAPSHOT
>
>
>
> The GEOSERVER_DATA_DIR environment variable is not defined correctly.
>
> Temporarily setting GEOSERVER_DATA_DIR to the following directory:
>
> C:\Users\astun\Desktop\geoserver-2.9-SNAPSHOT\data_dir
>
>
>
> Please wait while loading GeoServer...
>
>
>
> Error: Could not find or load main class
>
>
>
> Press any key to continue . . .
>
>
>
> for Java
>
>
>
> java version "1.8.0_77"
>
> Java(TM) SE Runtime Environment (build 1.8.0_77-b03)
>
> Java HotSpot(TM) 64-Bit Server VM (build 25.77-b03, mixed mode)
>
>
>
> Ian
>
>
>
> On 30 March 2016 at 13:36, Ben Caradoc-Davies <[email protected]> wrote:
>
> And please send us the full console output.
>
> Kind regards,
> Ben.
>
> On 31/03/16 01:07, Rahkonen Jukka (MML) wrote:
>
> > Hi,
> >
> > Have anybody tried to start master snapshots on Windows? The bin-zip
> that I downloaded today yields
> > Error: Could not find or load main class
> >
> > My jre version is jre1.8.0_72 (32-bit)
> >
> > -Jukka Rahkonen-
>
> --
> Ben Caradoc-Davies <[email protected]>
> Director
> Transient Software Limited <http://transient.nz/>
> New Zealand
>
>
> ------------------------------------------------------------------------------
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140
> _______________________________________________
> Geoserver-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/geoserver-devel
>
>
>
>
>
> --
>
> Ian Turton
>
>
> ------------------------------------------------------------------------------
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140
> _______________________________________________
> Geoserver-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/geoserver-devel
>
>
--
Ian Turton
------------------------------------------------------------------------------
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel