当前位置:网站首页>Yarn重启applications记录恢复
Yarn重启applications记录恢复
2022-07-01 13:00:00 【fanxl12】
Yarn重启applications记录恢复
Yarn重启applications记录恢复
修改yarn-core.xml配置文件
ResourceManager重启恢复
将yarn-site.xml中的
yarn.resourcemanager.recovery.enabled配置项设为true(默认是false)<property> <name>yarn.resourcemanager.recovery.enabled</name> <value>true</value> </property>配置
yarn.resourcemanager.store.class参数,该参数用来指定RM在重启之前将自己的状态保存在何种存储媒介上,目前有3种存储可选org.apache.hadoop.yarn.server.resourcemanager.recovery.FileSystemRMStateStore
默认值,是基于文件系统的存储(本地存储或者HDFS)。可以指定yarn.resourcemanager.fs.state-store.uri作为存储路径,如果指定这个yarn.resourcemanager.fs.state-store.uri必须要设置。org.apache.hadoop.yarn.server.resourcemanager.recovery.ZKRMStateStore
基于ZooKeeper的存储,当启用RM高可用时,只能选择这种方式。因为两个RM都有可能是活跃的(认为自己才是真正的RM),进而发生脑裂。基于ZK的存储可以通过隔离(fence)状态数据防止脑裂。可以指定hadoop.zk.address(ZK节点地址列表)和yarn.resourcemanager.zk-state-store.parent-path(状态数据的根节点路径)参数。org.apache.hadoop.yarn.server.resourcemanager.recovery.LeveldbRMStateStore
基于LevelDB的存储。它比前两种方式都更轻量级,占用的存储空间和I/O要小得多,并且支持更好的原子性操作。对性能有极致要求时采用。可以指定yarn.resourcemanager.leveldb-state-store.path作为存储路径。<property> <name>yarn.resourcemanager.store.class</name> <value>org.apache.hadoop.yarn.server.resourcemanager.recovery.FileSystemRMStateStore</value> </property>
配置yarn.resourcemanager.fs.state-store.uri,如果yarn.resourcemanager.store.class是org.apache.hadoop.yarn.server.resourcemanager.recovery.FileSystemRMStateStore需要配置,这里配置HDFS存储
<property> <name>yarn.resourcemanager.fs.state-store.uri</name> <value>hdfs://hadoop-master:9010/rmstore</value> </property>最后配置yarn.resourcemanager.work-preserving-recovery.scheduling-wait-ms,它表示从RM重启后从各个NM同步Container信息的等待时长,在此之后才会分配新的Container。默认值是10000(10秒),一般不需要改动。
<property> <name>yarn.resourcemanager.work-preserving-recovery.scheduling-wait-ms</name> <value>10000</value> </property>
配置NodeManager重启自动恢复
将yarn-site.xml中的
yarn.nodemanager.recovery.enabled配置项设为true(默认是false)<property> <name>yarn.nodemanager.recovery.enabled</name> <value>true</value> </property>配置
yarn.nodemanager.recovery.dir参数,指定NM在重启之前,将Container的状态写入此本地路径。默认值为${hadoop.tmp.dir}/yarn-nm-recovery<property> <name>yarn.nodemanager.recovery.dir</name> <value>/opt/topology/db_data/hadoop-data/yarn-nm-recovery</value> </property>配置
yarn.nodemanager.address参数,该参数为NM的RPC地址,默认为${yarn.nodemanager.hostname}:0,即随机使用临时端口。一定要指定为一个固定端口(如8041),否则NM重启之后会更换端口,就无法恢复Container的状态了<property> <name>yarn.nodemanager.address</name> <value>hadoop-master:45454</value> </property>
边栏推荐
- The popular major I chose became "Tiankeng" four years later
- nexus搭建npm依赖私库
- Which securities company has a low, safe and reliable account opening commission
- How to play with the reading and writing operations of blocking sockets?
- The difference between memcpy and strcpy
- Sharing with the best paper winner of CV Summit: how is a good paper refined?
- Asp. NETCORE uses dynamic to simplify database access
- Report on the "14th five year plan" and investment strategy recommendations for China's industrial robot industry 2022 ~ 2028
- Meta enlarge again! VR new model posted on CVPR oral: read and understand voice like a human
- JS变色的乐高积木
猜你喜欢
Example code of second kill based on MySQL optimistic lock
![[today in history] July 1: the father of time sharing system was born; Alipay launched barcode payment; The first TV advertisement in the world](/img/41/76687ea13e1722654b235f2cfa66ce.png)
[today in history] July 1: the father of time sharing system was born; Alipay launched barcode payment; The first TV advertisement in the world

MySQL statistical bill information (Part 2): data import and query

彩色五角星SVG动态网页背景js特效
![leetcode:226. Flip binary tree [DFS flip]](/img/b8/6c5596ac30de59f0f347bb0bddf574.png)
leetcode:226. Flip binary tree [DFS flip]

Ikvm of toolbox Net project new progress

简单的两个圆球loading加载
MySQL报错1040Too many connections的原因以及解决方案

Detailed explanation of OSPF LSA of routing Foundation

ZABBIX 6.0 source code installation and ha configuration
随机推荐
MySQL statistical bill information (Part 2): data import and query
Project deployment is not difficult at all!
Three stages of aho
软件测试中功能测试流程
The sky is blue and misty
Router. use() requires a middleware function but got a Object
leetcode 322. Coin Change 零钱兑换(中等)
Operator-1 first acquaintance with operator
VM virtual machine configuration dynamic IP and static IP access
Asp. NETCORE uses dynamic to simplify database access
题目 1004: 母牛的故事(递推)
VM虚拟机配置动态ip和静态ip访问
How to play with the reading and writing operations of blocking sockets?
MySQL Replication中的并行复制示例详解
During Oracle CDC data transmission, the CLOB type field will lose its value during update. There is a value before update, but
79. 单词搜索【dfs + 回溯visit + 遍历起点】
王兴的无限游戏迎来“终极”一战
MySQL报错1040Too many connections的原因以及解决方案
Example code of second kill based on MySQL optimistic lock
数字化转型再下一城,数字孪生厂商优锘科技宣布完成超3亿元融资