Download - Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Transcript
Page 1: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Analyzing Historical Data of Applications on Hadoop

YARN: for Fun and ProfitMayank Bansal, Zhijie Shen

Page 2: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Agenda

• Who we are ?

• Why we need New History Server?

• Application History Server

• Timeline Server

• Future Work

Page 3: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Who we are

• Hadoop Architect @ ebay• Apache Hadoop Committer• Apache Oozie PMC and Committer

• Current• Leading Hadoop Core Development for

YARN and MapReduce @ ebay

• Past• Working on Scheduler / Resource

Managers• Working on Distributed Systems• Data Pipeline frameworks

Mayank Bansal

Page 4: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Who we are

• Software Engineer @ Hortonworks• Apache Hadoop Committer• Apache SAMZA PPMC and Committer

Zhijie Shen

Page 5: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Agenda

• Who we are ?

• Why we need New History Server?

• Application History Server

• Application Timeline Server

• Future Work

Page 6: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

MR JobHistory Server

• We already have Job History Server

• It is only for Map Reduce Customized

• Storage is HDFS only

• Storage is very MR specific

• Counters

• Mappers and Reducers

• If you have only Map Reduce you are good.

Page 7: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Hadoop-2

Single Use System Batch Apps

Multi Purpose PlatformBatch, Interactive, streaming

Page 8: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

YARN

Page 9: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Issues with current Job History

• What if I have other Applications

• RM crashes

• Hard Limit on # Apps

• Upgrades / Updates

Page 10: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Agenda

• Who we are ?

• Why we need New History Server?

• Application History Server

• Timeline Server

• Future Work

Page 11: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Application History Server

• Separate Process

• Pluggable Storage

• HDFS

• In-Memory

• Resource Manager directly writes to Storage

• Aggregated Logs

• Separate UI, CLI and Rest End Point

Page 12: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Application History Server

Storage:

• It stores generic Data

• Application level data (queue, user etc…)

• List of ApplicationAttempts

• Information about each ApplicationAttempt

• List of containers for ApplicationAttempt

• Generic information about each container.

Page 13: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Application History Server

Page 14: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Application History Server

• CLI Interface $ yarn application -status <Application ID> $ yarn applicationattempt -list <Application ID>

• REST APIs

• http://localhost:8188/ws/v1/applicationhistory/apps/appid

Page 15: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Application History Server

• Scalability for storage

• One file per application

• File format is protobuff

• Size of HDFS files

• Multiple RM threads writing to History Storage

# of Containers

100 1K 10 K 100K

Size of the File

19 KB 184 KB

1.8 MB 19 MB

Page 16: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Agenda

• Who we are ?

• Why we need New History Server?

• Application History Server

• Timeline Server

• Future Work

Page 17: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service - Motivation

• YARN takes care of it

– Relieving the application from monitoring service

• Application diversity– Framework specific metadata/metrics

Page 18: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Data Model

• Entity Type– An abstract concept of anything

• Entity

– One specific instance of a entity type

– Defining the relationship between entities

• Event

– Something happens to an entity

Page 19: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Architecture

• LevelDB Store

• Client Library

• REST Interfaces

Page 20: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Store

• LevelDB based store

– Key-value store

– Lightweight

– License compatible

• Implementing reader/writer interfaces

• Support data retention

Page 21: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Client

• TimelineClient

– Wrap over REST POST method

– POJO objects

• TimelineEntity

• TimelineEvent

– In Client/AM/Container

Page 22: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – APIs

• Rest APIs, JSON as the media

• Get timeline entities

– http://localhost:8188/ws/v1/timeline/{entityType}

• Get timeline entity

– http://localhost:8188/ws/v1/timeline/{entityType}/{entityId}

• Get timeline events

– http://localhost:8188/ws/v1/timeline/{entityType}/events

Page 23: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Security

• HTTP SPNEGO

• Kerberos Authentication

• Delegation Token

– Performance

– AM/Container no Kerberos

• Access Control

– Admin/owner

– Timeline entity-level

Page 24: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Use Case (1)

Page 25: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Early Adopter (2)

Page 26: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Timeline Service – Early Adopter (3)

Page 27: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

Agenda

• Who we are ?

• Why we need New History Server?

• Application History Server

• Timeline Server

• Future Work

Page 28: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

To Be Continue…

• Integrating the generic history and

timeline data

• Rebasing MR Job history server on the

timeline server

• Making the timeline server rendering the

timeline data

Page 29: Hadoop Summit San Jose 2014 - Analyzing Historical Data of Applications on Hadoop YARN: for Fun and Profit

To Be Continue…

Scale

• Leveldb does not handle ebay scale

• We need something which can horizontally scale

• HBASE