openstack搭建准备工作
主机名与服务器ip地址
controller 192.168.23.98(控制节点)compute1 192.168.23.61(计算节点)
2.配置hosts解析
[root@controller ~]# vim /etc/hosts添加192.168.23.98 controller192.168.23.61 compute1[root@controller ~]# scp /etc/hosts root@compute1:/etc/hosts 要保证每个节点的hosts文件统一
3.验证
[root@controller ~]# ping -c 4 compute1PING compute1 (192.168.23.61) 56(84) bytes of data.64 bytes from compute1 (192.168.23.61): icmp_seq=1 ttl=64 time=0.639 ms64 bytes from compute1 (192.168.23.61): icmp_seq=2 ttl=64 time=0.307 ms64 bytes from compute1 (192.168.23.61): icmp_seq=3 ttl=64 time=0.324 ms64 bytes from compute1 (192.168.23.61): icmp_seq=4 ttl=64 time=0.312 ms--- compute1 ping statistics ---4 packets transmitted, 4 received, 0% packet loss, time 3000msrtt min/avg/max/mdev = 0.307/0.395/0.639/0.142 ms
5.关闭selinx和防火墙firewalld
以下命令所有节点都执行# sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config# setenforce 0# systemctl stop firewalld.service# systemctl disable firewalld.service# reboot# sestatus �Cv 检查是否关闭成功SELinux status: disabled
4.配置时间同步服务器(NTP)
控制节点[root@controller ~]# yum install chrony -y 安装服务[root@controller ~]# sed -i 's/#allow 192.168\/16/allow 192.168\/16/g' /etc/chrony.conf [root@controller ~]# cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime 更改时区启动NTP服务[root@controller ~]# systemctl enable chronyd.service[root@controller ~]# systemctl start chronyd.service配置计算节点[root@compute1 ~]# yum install chrony -y[root@compute1 ~]# sed -i 's/^server.*$//g' /etc/chrony.conf [root@compute1 ~]# sed -i "N;2aserver controller iburst" /etc/chrony.conf [root@compute1 ~]# cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime 更改时区启动NTP服务[root@compute1 ~]# systemctl enable chronyd.service[root@compute1 ~]# systemctl start chronyd.servic
5.openstack安装包
所有节点执行# yum install centos-release-openstack-newton -y# yum upgrade -y# yum install python-openstackclient openstack-selinux -y
基本的准备基本完成
本文出自 “linux运维” 博客,请务必保留此出处http://lijiawang.blog.51cto.com/10156897/1890696