Spark logs not overwriting

0 votes
Hi. I had a created a Spark application a long time ago and Spark has stored the logs. I don't need them now. I am running another application with the same name and what I want is that the logs of the new application should overwrite the logs of the previous application. How can I make this happen?
Mar 6 in Apache Spark by Sharan
4 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

Spark does not allow you to overwrite the files by default. There are two ways you can handle the situation.

You can either go to the location  file:///tmp/spark-events delete the directory of the previous application or its logs. 

Or you can just make Spark allow you to overwrite the log files:

val sc = new SparkContext(new SparkConf())
./bin/spark-submit <all your existing options> --spark.eventLog.overwrite=true
answered Mar 6 by Rohit

Related Questions In Apache Spark

0 votes
1 answer

How can I write a text file in HDFS not from an RDD, in Spark program?

Yes, you can go ahead and write ...READ MORE

answered May 29, 2018 in Apache Spark by Shubham
• 12,150 points
635 views
0 votes
1 answer

Not able to use sc in spark shell

Seems like master and worker are not ...READ MORE

answered Jan 3 in Apache Spark by Omkar
• 65,850 points
70 views
0 votes
1 answer
0 votes
1 answer

Spark context (sc) not found

Maybe the hadoop service didn't start properly. Try ...READ MORE

answered Feb 13 in Apache Spark by John
25 views
0 votes
0 answers
0 votes
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 9,030 points
1,654 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 9,030 points
130 views
0 votes
10 answers

hadoop fs -put command?

copy command can be used to copy files ...READ MORE

answered Dec 7, 2018 in Big Data Hadoop by Sujay
8,017 views
0 votes
1 answer

How to change the location of Spark event logs?

You can change the location where you ...READ MORE

answered Mar 6 in Apache Spark by Rohit
18 views
0 votes
1 answer

Invalid syntax in spark

There's a problem with your syntax. There ...READ MORE

answered Jan 31 in Apache Spark by Omkar
• 65,850 points
26 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.