一区二区三区在线-一区二区三区亚洲视频-一区二区三区亚洲-一区二区三区午夜-一区二区三区四区在线视频-一区二区三区四区在线免费观看

服務器之家:專注于服務器技術及軟件下載分享
分類導航

PHP教程|ASP.NET教程|Java教程|ASP教程|編程技術|正則表達式|C/C++|IOS|C#|Swift|Android|VB|R語言|JavaScript|易語言|vb.net|

服務器之家 - 編程語言 - Java教程 - Hadoop上Data Locality的詳解

Hadoop上Data Locality的詳解

2021-01-25 11:29csguo007 Java教程

這篇文章主要介紹了 Hadoop上Data Locality的詳解的相關資料,希望通過本文能幫助到大家,讓大家理解掌握這部分內(nèi)容,需要的朋友可以參考下

HadoopData Locality的詳解

Hadoop上的Data Locality是指數(shù)據(jù)與Mapper任務運行時數(shù)據(jù)的距離接近程度(Data Locality in Hadoop refers to the“proximity” of the data with respect to the Mapper tasks working on the data.)

1. why data locality is imporant?

當數(shù)據(jù)集存儲在HDFS中時,它被劃分為塊并存儲在Hadoop集群中的DataNode上。當在數(shù)據(jù)集執(zhí)行MapReduce作業(yè)時,各個Mappers將處理這些塊(輸進行入分片處理)。如果Mapper不能從它執(zhí)行的節(jié)點上獲取數(shù)據(jù),數(shù)據(jù)需要通過網(wǎng)絡從具有這些數(shù)據(jù)的DataNode拷貝到執(zhí)行Mapper任務的節(jié)點上(the data needs to be copied over the network from the DataNode which has the data to the DataNode which is executing the Mapper task)。假設一個MapReduce作業(yè)具有超過1000個Mapper,在同一時間每一個Mapper都試著去從集群上另一個DataNode節(jié)點上拷貝數(shù)據(jù),這將導致嚴重的網(wǎng)絡阻塞,因為所有的Mapper都嘗試在同一時間拷貝數(shù)據(jù)(這不是一種理想的方法)。因此,將計算任務移動到更接近數(shù)據(jù)的節(jié)點上是一種更有效與廉價的方法,相比于將數(shù)據(jù)移動到更接近計算任務的節(jié)點上(it is always effective and cheap to move the computation closer to the data than to move the data closer to the computation)。

2. How is data proximity defined?

當JobTracker(MRv1)或ApplicationMaster(MRv2)接收到運行作業(yè)的請求時,它查看集群中的哪些節(jié)點有足夠的資源來執(zhí)行該作業(yè)的Mappers和Reducers。同時需要根據(jù)Mapper運行數(shù)據(jù)所處位置來考慮決定每個Mapper執(zhí)行的節(jié)點(serious consideration is made to decide on which nodes the individual Mappers will be executed based on where the data for the Mapper is located)。

Hadoop上Data Locality的詳解

3. Data Local

當數(shù)據(jù)所處的節(jié)點與Mapper執(zhí)行的節(jié)點是同一節(jié)點,我們稱之為Data Local。在這種情況下,數(shù)據(jù)的接近度更接近計算( In this case the proximity of the data is closer to the computation.)。JobTracker(MRv1)或ApplicationMaster(MRv2)首選具有Mapper所需要數(shù)據(jù)的節(jié)點來執(zhí)行Mapper。

4. Rack Local

雖然Data Local是理想的選擇,但由于受限于集群上的資源,并不總是在與數(shù)據(jù)同一節(jié)點上執(zhí)行Mapper(Although Data Local is the ideal choice, it is not always possible to execute the Mapper on the same node as the data due to resource constraints on a busy cluster)。在這種情況下,優(yōu)選地選擇在那些與數(shù)據(jù)節(jié)點在同一機架上的不同節(jié)點上運行Mapper( In such instances it is preferred to run the Mapper on a different node but on the same rack as the node which has the data.)。在這種情況下,數(shù)據(jù)將在節(jié)點之間進行移動,從具有數(shù)據(jù)的節(jié)點移動到在同一機架上執(zhí)行Mapper的節(jié)點,這種情況我們稱之為Rack Local。

5. Different Rack

在繁忙的群集中,有時Rack Local也不可能。在這種情況下,選擇不同機架上的節(jié)點來執(zhí)行Mapper,并且將數(shù)據(jù)從具有數(shù)據(jù)的節(jié)點復制到在不同機架上執(zhí)行Mapper的節(jié)點。這是最不可取的情況。

如有疑問請留言或者到本站社區(qū)交流討論,感謝閱讀,希望能幫助到大家,謝謝大家對本站的支持!

原文鏈接:http://blog.csdn.net/zhyooo123/article/details/77868170

延伸 · 閱讀

精彩推薦
主站蜘蛛池模板: 国产肥女bbwbbw | 日本高清视频在线观看 | 九九热这里只有精品视频免费 | 国产精品毛片久久久久久久 | 精品国产乱码久久久人妻 | 嫩草精品 | 亚州春色| 成人影院观看 | 日本精工厂网址 | 日本色网址 | 国产精品亚洲午夜一区二区三区 | 久久精品视在线观看2 | 国产福利在线观看永久视频 | 亚洲欧洲日产国码天堂 | 日本在线观看免费观看完整版 | 国产成人高清视频 | 91tm视频 | 免费超级乱淫视频播放性 | 成人午夜影院在线观看 | 国内精品一区二区在线观看 | 日本精品一区二区三区 | 91色在线观看国产 | 成人福利视频网址 | 亚洲精品卡一卡2卡3卡4卡 | 男女姓交大视频免费观看 | 免费国产成人α片 | 男女福利视频 | 男女啪啪gif | tube8老师| 双子母性本能在线 | 美女隐私部位视频网站 | 日韩在线视频免费观看 | 青草草产国视频 | 交换朋友夫妇3中文字幕 | 久青草国产观看在线视频 | 天堂漫画破解版 | 亚洲精品国产一区二区在线 | 日韩一级片在线免费观看 | 男人在线影院 | 91sao国产在线观看 | 激性欧美激情在线aa |