当前位置:网站首页>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>
边栏推荐
- During Oracle CDC data transmission, the CLOB type field will lose its value during update. There is a value before update, but
- 运行Powershell脚本提示“因为在此系统上禁止运行脚本”解决办法
- Perl 5.10.0 installation package download
- 软件测试中功能测试流程
- 【历史上的今天】7 月 1 日:分时系统之父诞生;支付宝推出条码支付;世界上第一支电视广告
- SVG钻石样式代码
- flinkcdc要实时抽取oracle,对oracle要配置什么东西?
- Run PowerShell script prompt "because running script is prohibited on this system" solution
- R language builds a binary classification model based on H2O package: using H2O GBM build gradient hoist model GBM, use H2O AUC value of AUC calculation model
- Declare an abstract class vehicle, which contains the private variable numofwheel and the public functions vehicle (int), horn (), setnumofwheel (int) and getnumofwheel (). Subclass mot
猜你喜欢
Hardware development notes (9): basic process of hardware development, making a USB to RS232 module (8): create asm1117-3.3v package library and associate principle graphic devices
基因检测,如何帮助患者对抗疾病?
CS5268优势替代AG9321MCQ Typec多合一扩展坞方案
基于开源流批一体数据同步引擎 ChunJun 数据还原 —DDL 解析模块的实战分享
啟動solr報錯The stack size specified is too small,Specify at least 328k
VM虚拟机配置动态ip和静态ip访问
工具箱之 IKVM.NET 项目新进展
Nc100 converts strings to integers (ATOI)
[today in history] July 1: the father of time sharing system was born; Alipay launched barcode payment; The first TV advertisement in the world
Manage nodejs with NVM (downgrade the high version to the low version)
随机推荐
leetcode:329. 矩阵中的最长递增路径【dfs + cache + 无需回溯 + 优雅】
Project deployment is not difficult at all!
R language uses conf of yardstick package_ The mat function calculates the confusion matrix of the multiclass model on each fold of each cross validation (or resampling), and uses the summary to outpu
MHA high availability cluster deployment and failover of database
Who should I know when opening a stock account? Is it actually safe to open an account online?
CV顶会最佳论文得主分享:好论文是怎么炼成的?
Which securities company has a low, safe and reliable account opening commission
游戏公会在去中心化游戏中的未来
Redis explores cache consistency
Shangtang technology crash: a script written at the time of IPO
Zabbix 6.0 源码安装以及 HA 配置
Tencent always takes epoll, which is annoying
Nc100 converts strings to integers (ATOI)
The sky is blue and misty
Simple Fibonacci (recursive)
Function test process in software testing
Simple two ball loading
Topic 1004: the story of cows (recursion)
从数据库中更新一条数据,用cdc会同时获得op字段分别为d和c的两条数据吗?我记得之前是只有op为u
Development trend and market demand analysis report of China's high purity copper industry Ⓕ 2022 ~ 2028