Running SparkPi

575 views
Skip to first unread message

Venkat Nagaswamy

unread,
Jun 6, 2013, 1:30:41 AM6/6/13
to spark...@googlegroups.com
Hi
I am new to Spark and I am trying to run the example SparkPi.  I get the following error after a bunch of INFO messages.
Exception in thread "main" java.lang.NullPointerException
at java.net.URI$Parser.parse(URI.java:3004)
at java.net.URI.<init>(URI.java:577)
at spark.SparkContext.addJar(SparkContext.scala:511)
at spark.SparkContext$$anonfun$2.apply(SparkContext.scala:102)
at spark.SparkContext$$anonfun$2.apply(SparkContext.scala:102)
at scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:59)
at scala.collection.immutable.List.foreach(List.scala:76)
at spark.SparkContext.<init>(SparkContext.scala:102)
at spark.examples.SparkPi$.main(SparkPi.scala:14)
at spark.examples.SparkPi.main(SparkPi.scala)

I am running scala-2.9.3 (through macports) and Spark0.7.2 (with a clean sbt/sbt clean package install).  I am running it on Mountain Lion.  The directory examples/target has only the scala-2.9.3 directory which in turn has spark-examples_2.9.3-0.7.2.jar.  There are no other jars in the scala-2.9.3 directory.

Any help would be greatly appreciated.
Thanks
Venkat

Mridul Muralidharan

unread,
Jun 6, 2013, 7:28:55 AM6/6/13
to spark...@googlegroups.com
Looks like you might not have set the SPARK_EXAMPLES_JAR env variable
to point to the example jar.
spark master has been fixed to warn user about missing jar - but not
abort with an exception when it can recover.


Regards,
Mridul
> --
> You received this message because you are subscribed to the Google Groups
> "Spark Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to spark-users...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

Venkat Nagaswamy

unread,
Jun 6, 2013, 2:31:43 PM6/6/13
to spark...@googlegroups.com
That did it.  Thanks.
Reply all
Reply to author
Forward
0 new messages