机器准备(以4台机器进行说明)
- 安装操作系统,笔者以Centos7.8进行测试
- 笔者采用UltraISO进行系统安装,采用mini模式。
- 接下来进行了基本配置,包括ip,网络,时间同步等等
下面为其中一些操作:
sodu vi /etc/hosts
#############
xxx.xxx.xx.xx1 mycluster.master
xxx.xxx.xx.xx2 mycluster.slave1
xxx.xxx.xx.xx3 mycluster.slave2
xxx.xxx.xx.xx4 mycluster.slave3
##############
firewall-cmd –state
systemctl status firewalld
systemctl stop firewalld
systemctl disable firewalld
##############
vi /etc/selinux/config
SELINUX=disabled
###############
vi /etc/sysconfig/network-scripts/ifcfg-ens33
BOOTPROTO=static
ONBOOT=yes
IPADDR=xxx.xxx.xx.xxx
GATEWAY=YYY.YYY.YY.YYY
NETMASK=255.255.255.0
################
vi /etc/resolv.conf
nameserver 114.114.114.114
nameserver 223.5.5.5
################
nmcli c reload
nmcli networking off
nmcli networking on
################
yum –y install ntp
yum install httpd
systemctl status httpd
systemctl start httpd
chkconfig httpd on
################
ssh-keygen
ssh-copy-id root@mycluster.master
scp authorized_keys mycluster.slave1:/root/.ssh/
scp authorized_keys mycluster.slave2:/root/.ssh/
scp authorized_keys mycluster.slave3:/root/.ssh/
#################
vi /etc/ntp.conf
#添加配置
server ntp.aliyun.com
################
systemctl enable ntpd
systemctl restart ntpd
ntpdc –c loopinfo(查看与时间同步服务器的时间偏差)
ntpq –p(查看当前同步的时间服务器)
ntpstat(查看状态)
#(注:要生效可能要等差不多一分钟)
#################
后序的安装过程请参照下面这篇博文,写的比较详细
CDH6.3.2搭建详细步骤
一些报错
- 7180页面打不开
请执行命令查看报错详情 service --status-all - monitor报错:
vi /etc/security/limits.conf
###################
#在文件后加入下面内容:
soft nofile 100000
hard nofile 100000
#此步骤需要重启机器生效,可以设置完后再重启。
本文档详细记录了使用Centos7.8搭建集群的过程,包括操作系统安装、网络配置、防火墙关闭、SELINUX禁用、DNS设置、NTP同步以及SSH密钥配对。此外,还提到了解决7180页面无法打开的问题,通过修改limits.conf增加文件描述符限制以解决monitor报错。
1033

被折叠的 条评论
为什么被折叠?



