Packstack all-in-one方式安裝openstack queens版本


首先,本次環境詳情:VMware® Workstation 14 Pro + CentOS-7-x86_64-Minimal-1804.iso

     外網環境:192.168.123.0/24 ,虛擬機的ip是192.168.123.129

1. 更新環境:  yum update -y

2.更換centos 清華源:  

  詳情參考:https://mirrors.tuna.tsinghua.edu.cn/help/centos/

3.設置語言環境:

  vi /etc/environment 添加如下內容

  LANG=en_US.utf-8
  LC_ALL=en_US.utf-8

4.網絡設置

  (1)設置靜態IP

  (2)禁用firewalld、NetworkManager 

    sudo systemctl disable firewalld
    sudo systemctl stop firewalld
    sudo systemctl disable NetworkManager
    sudo systemctl stop NetworkManager
    sudo systemctl enable network
    sudo systemctl start network

       (3)selinux

    sudo vi /etc/selinux/config 修改SELINUX=disabled

    sudo setenfore 0

5.安裝openstack queens版本庫

  sudo yum install -y centos-release-openstack-queens

  sudo yum update -y

6.安裝packstack庫

  sudo yum install -y openstack-packstack

7.開始安裝

  (1)對於單節點OpenStack部署,請運行以下命令:sudo packstack --allinone

       (2)DIY設置

    a.生成配置文件:packstack --gen-answer-file=answer.ini

    b.修改配置文件,如: CONFIG_KEYSTONE_ADMIN_PW= #設置admin用戶的密碼

    c. 指定配置文件安裝openstack:packstack --answer-file=answer.ini

8.安裝完成:大約30分鍾

  完成此過程后,您可以登錄OpenStack Web界面Horizo​​n http://$YOURIP/dashboard

  用戶名是admin密碼可以在控制節點目錄中的文件keystonerc_admin找到/root

9.重新創建網絡

  先刪除已有的網絡,在界面-管理員-路由-刪除路由,然后刪除網絡

  在命令行: source keystonerc_admin

  neutron net-create --provider:network_type flat --provider:physical_network extnet --router:external  --shared external_network

  neutron subnet-create --name public_subnet --enable_dhcp=True --allocation-pool start=192.168.123.100,end=192.168.123.200 --gateway=192.168.123.2 external_network 192.168.123.0/24
  neutron net-create private_network
  neutron subnet-create --name private_subnet --allocation-pool start=10.10.1.100,end=10.10.1.200 --gateway=10.10.1.1 private_network 10.10.1.0/24
  neutron router-create router1
  neutron router-interface-add router1 private_subnet
  neutron router-gateway-set router1 external_network

9.Configure network interfaces以及創建實例

   參考:

  http://www.tuxfixer.com/create-project-tenant-in-openstack-and-launch-instances/

  http://wiki.christophchamp.com/index.php?title=OpenStack_deployment_via_packstack_from_RDO

  http://www.tuxfixer.com/install-openstack-newton-all-in-one-with-heat-orchestration-service-on-centos-7/

10.vnc無法正常使用

  在/etc/nova/nova.conf里修改如下內容:

  [vnc]   vnc_enabled = True   server_listen = 0.0.0.0   server_proxyclient_address = <node_ip_address>   novncproxy_base_url = http://<node_ip_address>:6080/vnc_auto.html

11.無法登陸dashboard

  查看iptables的狀態,若是開啟請關閉

  查看httpd的狀態,若是關閉請重啟


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM