Challenge - 5 Problems
Spark History Server Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediateSpark History Server Log Directory Listing
You have configured Spark History Server with the log directory set to
/var/log/spark-events. What is the output of the command ls /var/log/spark-events if the directory contains two completed application event logs named app-20240601-123456-0001 and app-20240601-123457-0002?Apache Spark
ls /var/log/spark-events
Attempts:
2 left
💡 Hint
Think about how the
ls command outputs multiple files in a directory by default.✗ Incorrect
The
ls command lists files line by line by default when output is to a terminal. So each file name appears on its own line.🧠 Conceptual
intermediatePurpose of Spark History Server
What is the main purpose of the Spark History Server in a Spark cluster?
Attempts:
2 left
💡 Hint
Think about what happens after a Spark job finishes and you want to review its details.
✗ Incorrect
The Spark History Server reads event logs from completed applications and provides a web UI to analyze job stages, tasks, and metrics after the job finishes.
❓ Configuration
advancedConfiguring Spark History Server Log Directory
Which configuration property must be set in
spark-defaults.conf to specify the directory where Spark History Server reads event logs?Attempts:
2 left
💡 Hint
Look for the property that starts with
spark.history and relates to the log directory.✗ Incorrect
The property
spark.history.fs.logDirectory defines the directory path where the Spark History Server looks for event logs.❓ Troubleshoot
advancedSpark History Server Not Showing Completed Applications
You started the Spark History Server and pointed it to the correct event log directory, but no completed applications appear in the UI. What is the most likely cause?
Attempts:
2 left
💡 Hint
Think about what must happen during Spark job execution for the History Server to have logs to read.
✗ Incorrect
If event logging is not enabled in Spark applications, no event logs are created, so the History Server has nothing to display.
✅ Best Practice
expertBest Practice for Spark Event Log Storage
For a production Spark cluster with many completed jobs, what is the best practice for storing Spark event logs to ensure efficient monitoring with Spark History Server?
Attempts:
2 left
💡 Hint
Consider accessibility and scalability for multiple Spark nodes and the History Server.
✗ Incorrect
Using a shared distributed filesystem like HDFS or S3 ensures all nodes and the History Server can access event logs reliably and scalably.
