配置虚拟机

182 阅读1分钟

1、配置环境

  • 关闭防火墙服务

    停止并禁用防火墙

    systemctlstopfirewalldsystemctl stop firewalld systemctl disable firewalld

  • 关闭并禁用SELinux

    若当前启用了 SELinux 则需要临时设置其当前状态为 permissive

    $ setenforce 0

    编辑/etc/sysconfig selinux 文件,以彻底禁用 SELinux

    sedis/SELINUX=enforcing sed -i 's/^SELINUX=enforcing/SELINUX=disabled/' /etc/selinux/config

    查看selinux状态

    $ getenforce

如果selinux状态为permissive,则执行reboot重新启动即可

2. 配置网络

具体配置可以参考这个链接

blog.csdn.net/dingguanyi/…

如多机 ping 通,/etc/hosts 中添加信息

如:

127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6 
168.107.130 master 
192.168.107.131 node01 
192.168.107.132 node02 
192.168.107.134 wf

待续……