title: Spark Executor logs in local or standalone mode
body: <p>I am running spark submit job in my local environment and to debug the whole process want to see the executor logs. For this I have made following changes :-</p>
  <ol>
  <li><p>Editing the log4j property file - 2 property files, one each for executor and one for driver</p>
  <pre><code>log4j.rootCategory=DEBUG, file
  log4j.appender.file=org.apache.log4j.FileAppender
  log4j.appender.file.File=/tmp/executor-application.log
  log4j.appender.file.append=false
  log4j.appender.file.layout=org.apache.log4j.PatternLayout
  log4j.appender.file.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
  </code></pre>
  </li>
  </ol>
  <p>2- Adding the log details into <strong>spark-default.conf</strong> file</p>
  <pre><code> spark.executor.extraJavaOptions=-Dlog4j.configuration=file:/spark-setup/conf/log4j-executor.properties
   spark.driver.extraJavaOptions=-Dlog4j.configuration=file:/spark-setup/conf/log4j-driver.properties
  </code></pre>
  <p>When I run the spark-submit job locally, I see only the driver logs not the executor log.</p>
  <pre><code>spark-submit --master &quot;local[*]&quot; --class com.test.action.myjob test_job.jar 
  </code></pre>
  <p>Am I missing something ?? why I can't see the executor logs ??
  Any pointers will help.</p>
  <p>thanks</p>