这里采用的是虚拟机做的一个Openstack 多节点的企业私有云平台测试,仅供参考
编号 | 系统 | 主机名–身份 | IP |
---|---|---|---|
@1 | centos7 | ct–控制节点 | NAT:eth0=192.168.11.51 主机:eth1=192.168.10.41 |
@2 | centos7 | c1–计算节点 | NAT:eth0=192.168.11.52 主机:eth1=192.168.10.42 |
@1@1@1
[root@local ~]# hostnamectl set-hostname ct //修改主机名@1改为ct @2改为c1
[root@ct ~]# cat >> /etc/hosts <<EOF
192.168.10.41 ct
192.168.10.42 c1
192.168.10.11 b1
EOF
配置yum源
[root@ct ~]# yum -y install httpd //使用httpd共享
[root@ct ~]# sed -i ‘/#S/s/#//’ /etc/httpd/conf/httpd.conf
[root@ct ~]# vmware-hgfsclient //注意共享目录
html
[root@ct ~]# vmhgfs-fuse .host:/html /var/www/html/ -o subtype=vmhgfs-fuse,allow_other //注意目录挂载位置
[root@ct ~]# systemctl start httpd && systemctl enable httpd
[root@ct ~]# echo “.host:/html /var/www/html/ fuse.vmhgfs-fuse allow_other,defaults 0 0”>> /etc/fstab //写入开机自动挂载
[root@ct ~]# vim /etc/yum.repos.d/local.repo //编辑yum源文件
[base]
name=base
baseurl=http://192.168.11.51/base
enabled=1
gpgcheck=0
[centos-openstack-train]
name=centos-openstack-train
baseurl=http://192.168.11.51/centos-openstack