diff --git a/elasticsearch/x-pack/shield/bin/xpack/syskeygen b/elasticsearch/x-pack/shield/bin/xpack/syskeygen index be326789b11..a79ef3808ec 100755 --- a/elasticsearch/x-pack/shield/bin/xpack/syskeygen +++ b/elasticsearch/x-pack/shield/bin/xpack/syskeygen @@ -134,7 +134,7 @@ if [ "x$JAVA_TOOL_OPTIONS" != "x" ]; then fi cd "$ES_HOME" > /dev/null -$JAVA $ES_JAVA_OPTS -cp "$ES_CLASSPATH" -Des.path.home="$ES_HOME" $properties org.elasticsearch.shield.crypto.tool.SystemKeyTool "$@" +"$JAVA" $ES_JAVA_OPTS -cp "$ES_CLASSPATH" -Des.path.home="$ES_HOME" $properties org.elasticsearch.shield.crypto.tool.SystemKeyTool "$@" status=$? cd - > /dev/null exit $status diff --git a/elasticsearch/x-pack/watcher/bin/xpack/croneval b/elasticsearch/x-pack/watcher/bin/xpack/croneval index c2561b29245..04abd90c385 100755 --- a/elasticsearch/x-pack/watcher/bin/xpack/croneval +++ b/elasticsearch/x-pack/watcher/bin/xpack/croneval @@ -125,7 +125,7 @@ if [ "x$JAVA_TOOL_OPTIONS" != "x" ]; then fi cd "$ES_HOME" > /dev/null -$JAVA $ES_JAVA_OPTS -cp "$ES_CLASSPATH" org.elasticsearch.watcher.trigger.schedule.tool.CronEvalTool "$@" $properties +"$JAVA" $ES_JAVA_OPTS -cp "$ES_CLASSPATH" -Des.path.home="$ES_HOME" org.elasticsearch.watcher.trigger.schedule.tool.CronEvalTool "$@" $properties status=$? cd - > /dev/null exit $status