title: Cannot run Spark 1.2 on YARN
body: <p>I'm having trouble running a simple java app on YARN using spark 1.2.  </p>
  
  <p>When running: </p>
  
  <pre><code>spark-submit --class SQL --master yarn-client --executor-memory 2g
  --executor-cores 1 target/learning-spark-mini-example-0.0.1.jar
  </code></pre>
  
  <p>I get this error:
  <a href="http://pastebin.com/4VHDDunj" rel="nofollow">http://pastebin.com/4VHDDunj</a></p>
  
  <p>During the execution, <code>spark-assembly-1.2.0-hadoop2.4.0.jar</code> is transmitted over the network, which takes a very long time.
  Seems weird, why upload such a big file? Shouldn't it already be on the cluster?</p>
  
  <p>Here is the configuration I'm using: 
  <a href="http://pastebin.com/qVsC5qdM" rel="nofollow">http://pastebin.com/qVsC5qdM</a>.</p>
  
  <p>It should be noted that no username or password is anywhere specified.
  It's not clear to me where I should set them.
  Spark tries to use my local "lorenzo" username on the cluster (where it also exists).</p>
  
  <p>Any help will be appreciated.</p>