Monitoring the state of Spark applications
To evaluate the performance of Spark applications in a Yandex Data Processing cluster, you can check the following:
- Application list
- Application logs
- Application queue
- Application details
- Resources allocated to the application
- Persisted RDDs
- List of SQL queries and their execution plans
Note
Make sure the cluster has the component web interfaces enabled. If not, enable them.
Checking the application list
- Open the folder dashboard
. - Go to Yandex Data Processing.
- Click the name of your cluster.
- Under UI Proxy, select
YARN Resource Manager Web UI.
It shows information about all running and completed applications.
Checking application logs
-
Open the folder dashboard
. -
Go to Yandex Data Processing.
-
Click the name of your cluster.
-
Under UI Proxy, select
YARN Resource Manager Web UI. -
Find the application you need and click its ID in the ID column.
This will open a window with info on the application's performance and a table listing its run attempts.
-
Click the link next to the attempt in question in the Logs column.
Checking the application queue
- Open the folder dashboard
. - Go to Yandex Data Processing.
- Click the name of your cluster.
- Under UI Proxy, select
YARN Resource Manager Web UI. - In the left-hand menu, navigate to Scheduler.
The Application Queues section shows the queue of applications and the resources they use.
Checking application details
-
Open the folder dashboard
. -
Go to Yandex Data Processing.
-
Click the name of your cluster.
-
Under UI Proxy, select
YARN Resource Manager Web UI. -
Find the application in question and follow the link in the Tracking UI column. The link name depends on the application status:
- ApplicationMaster for running applications
- History for completed applications
-
Open the folder dashboard
. -
Go to Yandex Data Processing.
-
Click the name of your cluster.
-
Under UI Proxy, select
Spark History Server Web UI.This will open the list of completed applications. To switch to the list of running applications, click Show incomplete applications at the bottom of the table.
-
Find the application in question and follow the link in the App ID column.
This will open the Spark History Server Web UI window with details on the application you selected:
- Event Timeline: History of job runs with info on added and removed executors.
- Active Jobs: List of jobs being run or pending.
- Completed Jobs: List of completed jobs.
For each job, the table specifies:
- Start time (Submitted)
- Duration
- Stages: Succeeded/Total
- Tasks: Succeeded/Total
Checking resources allocated to the application
- Open the folder dashboard
. - Go to Yandex Data Processing.
- Click the name of your cluster.
- Under UI Proxy, select
Spark History Server Web UI. - In the top menu, navigate to Executors.
The UI will display two tables:
- Summary: High-level information, such as the number and status of executors and resources in use.
- Executors: Information about each executor.
The tables specify the following:
- Amount of resources available per resource executor.
- Number of running and completed tasks.
- Task duration (Task Time), including the time spent on garbage collection (GC Time).
Tip
If garbage collection takes much time:
- Make sure you have enough memory allocated to the executor.
- Configure the garbage collector manually. To learn how to do this, see the Apache Spark documentation
.
Checking persisted RDDs
- Open the folder dashboard
. - Go to Yandex Data Processing.
- Click the name of your cluster.
- Under UI Proxy, select
Spark History Server Web UI. - In the top menu, navigate to Storage.
The UI displays the list of cacheable tables (RDDs
To view details, click the RDD name.
Checking the list of SQL queries and their execution plans
- Open the folder dashboard
. - Go to Yandex Data Processing.
- Click the name of your cluster.
- Under UI Proxy, select
Spark History Server Web UI. - In the top menu, navigate to SQL.
The table lists executed SQL queries, including their start time and duration.
To see the query execution plan, click the query text in the Description column. The query execution plan is displayed as a flowchart. To view it as text, click Details at the bottom of the figure.
The query execution plan contains stats for each operator along with the number of completed tasks and their duration. If the query is still running, the current stats will be shown.