2010-02-08 08:30:06 -05:00
|
|
|
@echo off
|
|
|
|
|
|
|
|
SETLOCAL
|
|
|
|
|
|
|
|
if NOT DEFINED JAVA_HOME goto err
|
|
|
|
|
|
|
|
set SCRIPT_DIR=%~dp0
|
|
|
|
for %%I in ("%SCRIPT_DIR%..") do set ES_HOME=%%~dpfI
|
|
|
|
|
|
|
|
|
|
|
|
REM ***** JAVA options *****
|
|
|
|
|
|
|
|
set JAVA_OPTS=^
|
2010-06-30 14:51:34 -04:00
|
|
|
-Xms256m^
|
2010-02-08 08:30:06 -05:00
|
|
|
-Xmx1G^
|
|
|
|
-Djline.enabled=false^
|
|
|
|
-XX:+AggressiveOpts^
|
|
|
|
-XX:+UseParNewGC^
|
|
|
|
-XX:+UseConcMarkSweepGC^
|
|
|
|
-XX:+CMSParallelRemarkEnabled^
|
|
|
|
-XX:+HeapDumpOnOutOfMemoryError
|
|
|
|
|
2010-05-06 14:07:24 -04:00
|
|
|
set ES_CLASSPATH=$CLASSPATH;"%ES_HOME%/lib/*";"%ES_HOME%/lib/sigar/*"
|
2010-02-08 08:30:06 -05:00
|
|
|
set ES_PARAMS=-Delasticsearch -Des-foreground=yes -Des.path.home="%ES_HOME%"
|
|
|
|
|
|
|
|
"%JAVA_HOME%\bin\java" %JAVA_OPTS% %ES_JAVA_OPTS% %ES_PARAMS% -cp "%ES_CLASSPATH%" "org.elasticsearch.bootstrap.Bootstrap"
|
|
|
|
goto finally
|
|
|
|
|
|
|
|
|
|
|
|
:err
|
|
|
|
echo JAVA_HOME environment variable must be set!
|
|
|
|
pause
|
|
|
|
|
|
|
|
|
|
|
|
:finally
|
|
|
|
|
|
|
|
ENDLOCAL
|