一、实验环境
(1)硬件:3 台 DELL R720 2*6核 48G内存 1T硬盘
(2)软件:vware workstation 14.0 , 创建30台虚拟机,Centos7.4 ,centos-release-openstack-queens, python-openstackclient,
(3)网络:每台虚拟机两块网卡,网桥模式eth0:172.16.70.0/24(管理网+API) ,eth1:10.16.70.0/24(olverlay)
二、节点规划
1):主机:controller1:172.16.70.201 安装:keystone,nova
2):主机:mq1:172.16.70.202 安装rabitmq
3):主机:mysql1:172.16.70.203 安装MariaDB
4):主机:nosql1:172.16.70.204 安装mongdb,memcache
(2)存储节点:
稍后补充
(3)网络节点:
稍后补充
(4)计算节点:
稍后补充
三、环境准备
(1)分配IP地址
配置#vim /etc/sysconfig/network-scripts/ifcfg-eth0 # 设置静态IP
NAME=eth0
DEVICE=eth0
ONBOOT=yes
IPADDR=172.16.70.201
NETMASK=255.255.255.0
GATEWAY=172.16.70.10
DNS1=202.96.128.166
#systemctl restart network #重启网络服务
也可以用nmtui(network manager text user interface)命令,进入网络管理器用户界面。
(2)关闭防火墙
systemctl disable firewalld
systemctl stop firewalld
sed 's/SELINUX=*/SELINUX=disabled/' /etc/selinux/config
(3)配置主机解析
#编辑vim /etc/hosts 文件,增加以下内容
172.16.70.201 controller1
172.16.70.202 mq1
172.16.70.203 mysql1
(4)时间同步
1)时间同步服务器端配置:vim /etc/chrony.conf
# Allow NTP client access from local network.
allow 172.16.70.0/24
查看同步情况
[root@controller1 ~]# chronyc sources
210 Number of sources = 4
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^? ntp1.ams1.nl.leaseweb.net 0 8 0 - +0ns[ +0ns] +/- 0ns
^? 85.199.214.100 0 8 0 - +0ns[ +0ns] +/- 0ns
^? static-5-103-139-163.ip.> 0 8 0 - +0ns[ +0ns] +/- 0ns
^? 85.199.214.101 0 8 0 - +0ns[ +0ns] +/- 0ns
2)客户端配置:vim /etc/chrony.conf
# Please consider joining the pool (http://www.pool.ntp.org/join.html).
#server 0.centos.pool.ntp.org iburst
#server 1.centos.pool.ntp.org iburst
#server 2.centos.pool.ntp.org iburst
#server 3.centos.pool.ntp.org iburst
server controller1 iburst
[root@mq1 ~]# chronyc sources
210 Number of sources = 1
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^? 172.16.70.201 0 8 0 - +0ns[ +0ns] +/- 0ns
(5)安装阿里epel源
下载epel,#wget rpm -ivh https://mirrors.aliyun.com/epel/epel-release-latest-7.noarch.rpm
安装 #rpm -ivh epel-release-latest-7.noarch.rpm
更新数据缓存#yum clean all && yum makecache
(6)安装OpenStack仓库的RPM包
# yum -y install centos-release-openstack-queens
# yum upgrade
(7)安装OpenStack 客户端
# yum -y install python-openstackclient
*将一台VWARE虚拟安装好以上这些环境,再通过克隆完成30台虚拟机(如果是物理机则通过COBBLER进行自动化部署参见:https://blog.csdn.net/openbox2008/article/details/80150199),再将分别将IP和主机名等配置好。