SlideShare ist ein Scribd-Unternehmen logo
1 von 32
HDFS原理与实现 刘景龙
主要内容 HDFS简介 系统架构 面临的挑战 解决方案
什么是Hadoop? 基础架构(infrastructure) Reliable Scalable Distributed computing
Hadoop发展史
什么是HDFS? Hadoop Distributed File System Hadoop Distributed File System (HDFS) is the primary storage system used by Hadoop applications. HDFS creates multiple replicasof data blocks and distributes them on compute nodes throughout a cluster to enable reliable, extremely rapid computations.
HDFS能做什么? 存储并管理PB级数据 处理非结构化数据 注重数据处理的吞吐量(latency不敏感) ,[object Object],[object Object]
谁在用Hadoop?
主要内容 HDFS简介 系统架构 面临的挑战 解决方案
设计目标 假设: 节点失效是常态 理想:  1. 任何一个节点失效,不影响HDFS服务 2. HDFS可以自动完成副本的复制
设计目标 假设: write-once-read-many存取模式 不支持文件并发写入 不支持文件修改
HDFS主要组件
HDFS主要组件的功能
系统架构
Example:HDFS如何写文件? Create file  Close file Write packet Send ack Write packet Send ack Write packet Send ack
HDFS副本放置策略
Example:HDFS如何读文件? Open file Get block location Close file Read block
节点失效是常态 DataNode中的磁盘挂了怎么办? DataNode所在机器挂了怎么办? NameNode挂了怎么办? Client挂了怎么办?
DataNode的磁盘挂了怎么办? DataNode正常服务 坏掉的磁盘上的数据尽快通知NameNode
DataNode所在机器挂了怎么办? 问:NameNode怎么知道DataNode挂掉了? 答:datanode每3秒钟向namenode发送心跳,如果10分钟datanode没有向namenode发送心跳,则namenode认为该datanode已经dead,namenode将取出该datanode上对应的block,对其进行复制。
NameNode挂了怎么办? 持久化元数据 操作日志(edit log) 记录文件创建,删除,修改文件属性等操作 Fsimage 包含完整的命名空间 File -> Block的映射关系 文件的属性(ACL, quota, 修改时间等)
NameNode挂了怎么办? Secondary NameNode 将NameNode的fsimage与edit log从Namenode复制到临时目录 将fsimage同edit log合并,并产生新的fsimage 将产生的新的fsimage上传给NameNode 清除NameNode中的edit log [注]: Secondary NameNode仅仅对NameNode中元数据提供冷备方案
Client挂了怎么办? 问: Client 所在机器挂了有什么影响? 答:一致性问题 Lease recovery Create file, get lease  Crash Renew lease
write-once-read-many 读写流程 不支持并发写入 通过lease机制 不支持对文件修改
主要内容 HDFS简介 系统架构 面临的挑战 解决方案
面临的挑战 可扩展性 集群规模扩大:1000 -> 5000/10000 数据规模的增长: 1亿-> 5亿/10亿 单点的Master/NameNode内存,所有的元数据都存储于NameNode的内存 负载,集群规模扩大后,单点的NameNode请求压力也会同时增大 可用性
解决方案:HDFS2 设计目标: 文件支撑到1万节点、10亿文件的集群规模 独立的对象管理层 可插入式namespace
解决方案:HDFS2 NameNode namespace blockMap
解决方案:HDFS2 Nameode Namespace namespace blockMap FMS1 FMS2
发展计划
回顾 什么是hadoop hdfs是用来做什么的 hdfs的主要假设是什么? hdfs针对假设做了些什么? 面临的挑战 (还需要做什么?) 如何解决的?
Q & A Thanks
Hdfs原理及实现

Weitere ähnliche Inhalte

Was ist angesagt?

Hbase架构简介、实践
Hbase架构简介、实践Hbase架构简介、实践
Hbase架构简介、实践Li Map
 
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹Apache hadoop and cdh(cloudera distribution) introduction 基本介紹
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹Anna Yen
 
分布式存储的元数据设计
分布式存储的元数据设计分布式存储的元数据设计
分布式存储的元数据设计LI Daobing
 
hadoop中的懒人Hive
hadoop中的懒人Hivehadoop中的懒人Hive
hadoop中的懒人Hivechernbb
 
1.4 go在数据存储上面的应用—毛剑
1.4 go在数据存储上面的应用—毛剑1.4 go在数据存储上面的应用—毛剑
1.4 go在数据存储上面的应用—毛剑Leo Zhou
 
Memcached vs redis
Memcached vs redisMemcached vs redis
Memcached vs redisqianshi
 
What could hadoop do for us
What could hadoop do for us What could hadoop do for us
What could hadoop do for us Simon Hsu
 
redis 适用场景与实现
redis 适用场景与实现redis 适用场景与实现
redis 适用场景与实现iammutex
 
Ted yu:h base and hoya
Ted yu:h base and hoyaTed yu:h base and hoya
Ted yu:h base and hoyahdhappy001
 
Couchbase introduction - Chinese
Couchbase introduction - Chinese Couchbase introduction - Chinese
Couchbase introduction - Chinese Vickie Zeng
 
大规模数据处理
大规模数据处理大规模数据处理
大规模数据处理Kay Yan
 
Hadoop 2.0 之古往今來
Hadoop 2.0 之古往今來Hadoop 2.0 之古往今來
Hadoop 2.0 之古往今來Wei-Yu Chen
 
高可用可扩展数据库架构方案探讨
高可用可扩展数据库架构方案探讨高可用可扩展数据库架构方案探讨
高可用可扩展数据库架构方案探讨Sky Jian
 
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬Hang Geng
 
使用Ubuntu架設hadoop
使用Ubuntu架設hadoop使用Ubuntu架設hadoop
使用Ubuntu架設hadooptaishanla
 
Hadoop 簡介 教師 許智威
Hadoop 簡介 教師 許智威Hadoop 簡介 教師 許智威
Hadoop 簡介 教師 許智威Awei Hsu
 

Was ist angesagt? (20)

Hbase架构简介、实践
Hbase架构简介、实践Hbase架构简介、实践
Hbase架构简介、实践
 
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹Apache hadoop and cdh(cloudera distribution) introduction 基本介紹
Apache hadoop and cdh(cloudera distribution) introduction 基本介紹
 
分布式存储的元数据设计
分布式存储的元数据设计分布式存储的元数据设计
分布式存储的元数据设计
 
hadoop中的懒人Hive
hadoop中的懒人Hivehadoop中的懒人Hive
hadoop中的懒人Hive
 
1.4 go在数据存储上面的应用—毛剑
1.4 go在数据存储上面的应用—毛剑1.4 go在数据存储上面的应用—毛剑
1.4 go在数据存储上面的应用—毛剑
 
Memcached vs redis
Memcached vs redisMemcached vs redis
Memcached vs redis
 
What could hadoop do for us
What could hadoop do for us What could hadoop do for us
What could hadoop do for us
 
Dfs ning
Dfs ningDfs ning
Dfs ning
 
关于Hbase
关于Hbase关于Hbase
关于Hbase
 
redis 适用场景与实现
redis 适用场景与实现redis 适用场景与实现
redis 适用场景与实现
 
大數據
大數據大數據
大數據
 
H base云存储
H base云存储H base云存储
H base云存储
 
Ted yu:h base and hoya
Ted yu:h base and hoyaTed yu:h base and hoya
Ted yu:h base and hoya
 
Couchbase introduction - Chinese
Couchbase introduction - Chinese Couchbase introduction - Chinese
Couchbase introduction - Chinese
 
大规模数据处理
大规模数据处理大规模数据处理
大规模数据处理
 
Hadoop 2.0 之古往今來
Hadoop 2.0 之古往今來Hadoop 2.0 之古往今來
Hadoop 2.0 之古往今來
 
高可用可扩展数据库架构方案探讨
高可用可扩展数据库架构方案探讨高可用可扩展数据库架构方案探讨
高可用可扩展数据库架构方案探讨
 
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬
Ceph中国社区9.19 Ceph FS-基于RADOS的高性能分布式文件系统02-袁冬
 
使用Ubuntu架設hadoop
使用Ubuntu架設hadoop使用Ubuntu架設hadoop
使用Ubuntu架設hadoop
 
Hadoop 簡介 教師 許智威
Hadoop 簡介 教師 許智威Hadoop 簡介 教師 許智威
Hadoop 簡介 教師 許智威
 

Andere mochten auch

CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...
CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...
CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...Chicago eLearning & Technology Showcase
 
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost World
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost WorldCETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost World
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost WorldChicago eLearning & Technology Showcase
 
English iii rico the dog
English iii rico the dogEnglish iii rico the dog
English iii rico the dogMeibel Chaves
 
140321_株式会社MK翻訳事務所_会社紹介
140321_株式会社MK翻訳事務所_会社紹介140321_株式会社MK翻訳事務所_会社紹介
140321_株式会社MK翻訳事務所_会社紹介MK Translation Firm
 
Problem management in Steria operations
Problem management in Steria operationsProblem management in Steria operations
Problem management in Steria operationsAndreas Aasen
 
Kozłowska - projekt
Kozłowska - projektKozłowska - projekt
Kozłowska - projektRobert
 
EclipseCon USA 2011 Virgo and RT playing together
EclipseCon USA 2011 Virgo and RT playing togetherEclipseCon USA 2011 Virgo and RT playing together
EclipseCon USA 2011 Virgo and RT playing togetherChristopher Frost
 
투이컨설팅 제24회 Y세미나 : 설문결과
투이컨설팅 제24회 Y세미나 : 설문결과투이컨설팅 제24회 Y세미나 : 설문결과
투이컨설팅 제24회 Y세미나 : 설문결과2econsulting
 

Andere mochten auch (20)

CETS 2013, Tracy Adams, slides for Make It Once, Use it Twice
CETS 2013, Tracy Adams, slides for Make It Once, Use it TwiceCETS 2013, Tracy Adams, slides for Make It Once, Use it Twice
CETS 2013, Tracy Adams, slides for Make It Once, Use it Twice
 
Bgt2
Bgt2Bgt2
Bgt2
 
Cets 2013_ gander hale_write_test_questions_session
Cets 2013_ gander hale_write_test_questions_sessionCets 2013_ gander hale_write_test_questions_session
Cets 2013_ gander hale_write_test_questions_session
 
CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...
CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...
CETS 2011, Elizabeth Raichle Wolfe, Using Social Media to Lead Learners to Th...
 
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost World
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost WorldCETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost World
CETS 2011, Steve Baker, slides for High-Impact Videos in a Low-Cost World
 
Fazd Bovine Babesiosis
Fazd Bovine BabesiosisFazd Bovine Babesiosis
Fazd Bovine Babesiosis
 
English iii rico the dog
English iii rico the dogEnglish iii rico the dog
English iii rico the dog
 
Malaysia Freight Logistics: The Way Forward
Malaysia Freight Logistics: The Way ForwardMalaysia Freight Logistics: The Way Forward
Malaysia Freight Logistics: The Way Forward
 
Doc1
Doc1Doc1
Doc1
 
140321_株式会社MK翻訳事務所_会社紹介
140321_株式会社MK翻訳事務所_会社紹介140321_株式会社MK翻訳事務所_会社紹介
140321_株式会社MK翻訳事務所_会社紹介
 
Ideas First (IF) by Cradle Fund Sdn. Bhd.
Ideas First (IF) by Cradle Fund Sdn. Bhd.Ideas First (IF) by Cradle Fund Sdn. Bhd.
Ideas First (IF) by Cradle Fund Sdn. Bhd.
 
SkySimulator & DrFerozMusa
SkySimulator & DrFerozMusaSkySimulator & DrFerozMusa
SkySimulator & DrFerozMusa
 
Problem management in Steria operations
Problem management in Steria operationsProblem management in Steria operations
Problem management in Steria operations
 
Appendix c
Appendix cAppendix c
Appendix c
 
Kozłowska - projekt
Kozłowska - projektKozłowska - projekt
Kozłowska - projekt
 
Neusoft China
Neusoft ChinaNeusoft China
Neusoft China
 
Guangdong and Shenzhen 1
Guangdong and Shenzhen 1Guangdong and Shenzhen 1
Guangdong and Shenzhen 1
 
EclipseCon USA 2011 Virgo and RT playing together
EclipseCon USA 2011 Virgo and RT playing togetherEclipseCon USA 2011 Virgo and RT playing together
EclipseCon USA 2011 Virgo and RT playing together
 
투이컨설팅 제24회 Y세미나 : 설문결과
투이컨설팅 제24회 Y세미나 : 설문결과투이컨설팅 제24회 Y세미나 : 설문결과
투이컨설팅 제24회 Y세미나 : 설문결과
 
Cets 2014 hybert tips legal effective graphics
Cets 2014 hybert tips legal effective graphicsCets 2014 hybert tips legal effective graphics
Cets 2014 hybert tips legal effective graphics
 

Ähnlich wie Hdfs原理及实现

Hadoop-分布式数据平台
Hadoop-分布式数据平台Hadoop-分布式数据平台
Hadoop-分布式数据平台Jacky Chi
 
使用Ubuntu架設hadoop
使用Ubuntu架設hadoop使用Ubuntu架設hadoop
使用Ubuntu架設hadooptaishanla
 
Introduction to Hadoop
Introduction to HadoopIntroduction to Hadoop
Introduction to HadoopTechParty@UIC
 
Azure HDInsight 介紹
Azure HDInsight 介紹Azure HDInsight 介紹
Azure HDInsight 介紹Herman Wu
 
HDInsight for Hadoopers
HDInsight for HadoopersHDInsight for Hadoopers
HDInsight for HadoopersKuo-Chun Su
 
高科技產業資料分析解決方案 Hare DB
高科技產業資料分析解決方案 Hare DB高科技產業資料分析解決方案 Hare DB
高科技產業資料分析解決方案 Hare DBEtu Solution
 
Hadoop作业调度研究V0.1
Hadoop作业调度研究V0.1Hadoop作业调度研究V0.1
Hadoop作业调度研究V0.1YongqiangHe
 
HDInsight for Microsoft Users
HDInsight for Microsoft UsersHDInsight for Microsoft Users
HDInsight for Microsoft UsersKuo-Chun Su
 
Hue使用及规范
Hue使用及规范Hue使用及规范
Hue使用及规范edwardsbean
 
华为软件定义存储架构分析
华为软件定义存储架构分析华为软件定义存储架构分析
华为软件定义存储架构分析Liang Ming
 
大规模数据处理
大规模数据处理大规模数据处理
大规模数据处理airsex
 
HDFS-In-Cloud
HDFS-In-CloudHDFS-In-Cloud
HDFS-In-CloudLei Xu
 
Hdfs raid migration to hadoop 1.x
Hdfs raid migration to hadoop 1.x Hdfs raid migration to hadoop 1.x
Hdfs raid migration to hadoop 1.x Jiang Yu
 
Bigdata introduction
Bigdata introductionBigdata introduction
Bigdata introductionTechwiser
 
HDFS與MapReduce架構研討
HDFS與MapReduce架構研討HDFS與MapReduce架構研討
HDFS與MapReduce架構研討Billy Yang
 
Use Alluxio to Unify Storage Systems in Suning
Use Alluxio to Unify Storage Systems in SuningUse Alluxio to Unify Storage Systems in Suning
Use Alluxio to Unify Storage Systems in SuningAlluxio, Inc.
 
Hadoop系统及其关键技术
Hadoop系统及其关键技术Hadoop系统及其关键技术
Hadoop系统及其关键技术冬 陈
 

Ähnlich wie Hdfs原理及实现 (20)

Hadoop-分布式数据平台
Hadoop-分布式数据平台Hadoop-分布式数据平台
Hadoop-分布式数据平台
 
使用Ubuntu架設hadoop
使用Ubuntu架設hadoop使用Ubuntu架設hadoop
使用Ubuntu架設hadoop
 
Hdfs
HdfsHdfs
Hdfs
 
Introduction to Hadoop
Introduction to HadoopIntroduction to Hadoop
Introduction to Hadoop
 
Azure HDInsight 介紹
Azure HDInsight 介紹Azure HDInsight 介紹
Azure HDInsight 介紹
 
HDInsight for Hadoopers
HDInsight for HadoopersHDInsight for Hadoopers
HDInsight for Hadoopers
 
Hadoop
HadoopHadoop
Hadoop
 
高科技產業資料分析解決方案 Hare DB
高科技產業資料分析解決方案 Hare DB高科技產業資料分析解決方案 Hare DB
高科技產業資料分析解決方案 Hare DB
 
Hadoop作业调度研究V0.1
Hadoop作业调度研究V0.1Hadoop作业调度研究V0.1
Hadoop作业调度研究V0.1
 
HDInsight for Microsoft Users
HDInsight for Microsoft UsersHDInsight for Microsoft Users
HDInsight for Microsoft Users
 
Hue使用及规范
Hue使用及规范Hue使用及规范
Hue使用及规范
 
华为软件定义存储架构分析
华为软件定义存储架构分析华为软件定义存储架构分析
华为软件定义存储架构分析
 
大规模数据处理
大规模数据处理大规模数据处理
大规模数据处理
 
HDFS-In-Cloud
HDFS-In-CloudHDFS-In-Cloud
HDFS-In-Cloud
 
IT03
IT03IT03
IT03
 
Hdfs raid migration to hadoop 1.x
Hdfs raid migration to hadoop 1.x Hdfs raid migration to hadoop 1.x
Hdfs raid migration to hadoop 1.x
 
Bigdata introduction
Bigdata introductionBigdata introduction
Bigdata introduction
 
HDFS與MapReduce架構研討
HDFS與MapReduce架構研討HDFS與MapReduce架構研討
HDFS與MapReduce架構研討
 
Use Alluxio to Unify Storage Systems in Suning
Use Alluxio to Unify Storage Systems in SuningUse Alluxio to Unify Storage Systems in Suning
Use Alluxio to Unify Storage Systems in Suning
 
Hadoop系统及其关键技术
Hadoop系统及其关键技术Hadoop系统及其关键技术
Hadoop系统及其关键技术
 

Mehr von baggioss

Hdfs写流程异常处理
Hdfs写流程异常处理Hdfs写流程异常处理
Hdfs写流程异常处理baggioss
 
Hbase性能测试文档
Hbase性能测试文档Hbase性能测试文档
Hbase性能测试文档baggioss
 
Hbase使用hadoop分析
Hbase使用hadoop分析Hbase使用hadoop分析
Hbase使用hadoop分析baggioss
 
Hadoop基线选定
Hadoop基线选定Hadoop基线选定
Hadoop基线选定baggioss
 
Hic 2011 realtime_analytics_at_facebook
Hic 2011 realtime_analytics_at_facebookHic 2011 realtime_analytics_at_facebook
Hic 2011 realtime_analytics_at_facebookbaggioss
 
[Hi c2011]building mission critical messaging system(guoqiang jerry)
[Hi c2011]building mission critical messaging system(guoqiang jerry)[Hi c2011]building mission critical messaging system(guoqiang jerry)
[Hi c2011]building mission critical messaging system(guoqiang jerry)baggioss
 

Mehr von baggioss (8)

Hdfs写流程异常处理
Hdfs写流程异常处理Hdfs写流程异常处理
Hdfs写流程异常处理
 
Hbase性能测试文档
Hbase性能测试文档Hbase性能测试文档
Hbase性能测试文档
 
Hbase使用hadoop分析
Hbase使用hadoop分析Hbase使用hadoop分析
Hbase使用hadoop分析
 
Hadoop基线选定
Hadoop基线选定Hadoop基线选定
Hadoop基线选定
 
Hic 2011 realtime_analytics_at_facebook
Hic 2011 realtime_analytics_at_facebookHic 2011 realtime_analytics_at_facebook
Hic 2011 realtime_analytics_at_facebook
 
[Hi c2011]building mission critical messaging system(guoqiang jerry)
[Hi c2011]building mission critical messaging system(guoqiang jerry)[Hi c2011]building mission critical messaging system(guoqiang jerry)
[Hi c2011]building mission critical messaging system(guoqiang jerry)
 
Hic2011
Hic2011Hic2011
Hic2011
 
Hbase
HbaseHbase
Hbase
 

Hdfs原理及实现