amplab/shark — pull request #255 by boneill42 (2014-02-04 17:56:35+00:00)
Title: Fix for shark environment template when JAVA_OPTS is set.

The value of $SPARK_OPTS is concatenated directly onto the end of JAVA_OPTS in the run script.
(line 152)

Without a space in the shark-env.sh, this results in a parsing problem with existing JAVA_OPTS.

e.g.
bone@zen:~/tools/shark-0.8.0-bin-cdh4/shark-0.8.0-> grep JAVA_OPTS ~/.bash_profile
export JAVA_OPTS="-Xmx3096m"

results in:
Starting the Shark Command Line Client
Invalid maximum heap size: -Xmx3096m-Dspark.local.dir=/tmp
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.