其他分享
首页 > 其他分享> > OpenStack-T版基础环境

OpenStack-T版基础环境

作者:互联网

主机名 eth0(仅主机) eth1(nat)
控制 192.168.100.147 192.168.73.33
计算 192.168.100.148 192.168.73.24

控制节点 controller

修改主机名
[root@controller ~]#hostnamectl set‐hostname controller

关闭防火墙
[root@controller ~]#systemctl stop firewalld
[root@controller ~]#systemctl disable firewalld 查看防火墙是否关闭
firewall-cmd --state

换源
[root@controller ~]# yum install centos-release-openstack-train -y

升级软件包
[root@controller ~]#yum upgrade -y
安装 OpenStack 客户端
[root@controller ~]#yum install -y python-openstackclient
安装 OpenStack 软件包以自动管理OpenStack服务的安全策略
[root@controller ~]#yum install openstack-selinux -y

关闭selinux
[root@controller ~]#setenforce 0
[root@controller ~]#sed -i 's/enforcing/disabled/g' /etc/selinux/config

配置域名解析
[root@controller ~]#echo "192.168.100.147 controller" >>/etc/hosts
[root@controller ~]#echo "192.168.100.148 compute" >>/etc/hosts

配置 IP

网络时间协议
[root@controller ~]#yum install chrony vim ‐y
[root@controller ~]#vim /etc/chrony.conf
控制节点新增如下:
server controller iburst
allow 192.168.100.0/24
local stratum 10
重启服务
[root@controller ~]#systemctl restart chronyd
[root@controller ~]#systemctl enable chronyd
验证
[root@controller ~]#chronyc sources
[root@controller ~]#clock -w

计算节点 compute

修改主机名
hostnamectl set-hostname compute

配置 ip

关闭防火墙

systemctl stop firewalld

systemctl disable firewalld

查看防火墙是否关闭

firewalld-cmd --state

换源

yum install centos-release-openstack-train -y

升级软件包

yum upgrade -y

安装 OpenStack 客户端

yum install -y python-openstackclient

安装 OpenStack 软件包自动管理服务安全策略

yum install openstack-selinux -y

配置域名解析

echo "192.168.100.147 controller" >>/etc/hosts

echo "192.168.100.148 compute" >>/etc/hosts

关闭selinux

sed -i 's/enforcing/disabled/g' /etc/selinux/config

setenforce 0

配置 NTP 网络时间协议

yum install chrony vim -y //安装软件包

修改配置文件

vim /etc/chrony.conf

server controller iburst
重启服务并开机自启

systemctl restart chronyd

systemctl enable chronyd

验证

chronyc sources

当前系统时间写入到CMOS中

clock -w

标签:基础,环境,192.168,etc,controller,systemctl,yum,OpenStack,root
来源: https://www.cnblogs.com/dagu666/p/16561382.html