Hint: Resource allocation step requests containers from NodeManagers [OK]
Common Mistakes:
Confusing launchContainers() with resource requests
Thinking submitApplication() requests containers
Assuming cleanup() handles resource allocation
4. You see a YARN application stuck in the ACCEPTED state for a long time. What is the most likely cause?
medium
A. ResourceManager has no available resources to allocate
B. ApplicationMaster failed to launch
C. NodeManager crashed after container launch
D. Application has already completed
Solution
Step 1: Understand ACCEPTED state meaning
ACCEPTED means application is waiting for resources to be allocated.
Step 2: Identify cause of delay in allocation
If ResourceManager has no free resources, allocation is delayed, causing ACCEPTED state to persist.
Final Answer:
ResourceManager has no available resources to allocate -> Option A
Quick Check:
ACCEPTED = waiting for resources [OK]
Hint: Long ACCEPTED means no resources available [OK]
Common Mistakes:
Assuming ApplicationMaster failed immediately
Thinking NodeManager crash causes ACCEPTED state
Confusing ACCEPTED with COMPLETED state
5. You want to optimize a YARN application that spends too much time in the RUNNING state but finishes slowly. Which approach best improves the application lifecycle?
hard
A. Increase container memory and CPU to speed up task execution
B. Reduce the number of containers to limit resource usage
C. Submit the application multiple times in parallel
D. Disable ApplicationMaster monitoring to reduce overhead
Solution
Step 1: Analyze RUNNING state delay cause
Long RUNNING time means tasks are slow or resource-starved.
Step 2: Choose optimization method
Increasing container memory and CPU helps tasks run faster, reducing RUNNING time.