如何将namenode与SecondaryNameNode分开配置

2024-12-26 03:44:28
推荐回答(1个)
回答1:

1 增加masters文件 sudo vi masters slave1
2 修改hdfs-site.xml在下面文件中增加图片内容dfs.http.addressdfs.namenode.secondary.http-addressslave1:50090
3 修改core-site.xml文件

4 开始启动节点 start-dfs.sh
输入如下内容
Starting namenodes on [master]
master: starting namenode, logging to /usr/hadoop/logs/hadoop-aboutyun-namenode-master.out
slave2: starting datanode, logging to /usr/hadoop/logs/hadoop-aboutyun-datanode-slave2.out
slave1: starting datanode, logging to /usr/hadoop/logs/hadoop-aboutyun-datanode-slave1.out
Starting secondary namenodes [slave1]
slave1: starting secondarynamenode, logging to /usr/hadoop/logs/hadoop-aboutyun-secondarynamenode-slave1.out