您好,登录后才能下订单哦!
这篇文章主要介绍devstack如何安装openstack pike,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!
物理机操作系统:ubuntu-16.04.4-server-amd64
controller:192.168.18.61 ubuntu61
compute:192.168.18.62 ubuntu62
compute:192.168.18.63 ubuntu63
vi /etc/apt/source.list
deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse
apt-get update
apt-get install python-pip
检验是否安装成功:pip -V
cd /home
git clone https://git.openstack.org/openstack-dev/devstack -b stable/pike
国内源
git clone https://git.openstack.org/openstack-dev/devstack -b stable/pike
cd /home/devstack/tools/ ./create-stack-user.sh cd /home/ mv devstack /opt/stack chown -R stack:stack /opt/stack/devstack chmod 777 /dev/pts/0
分别为root和stack用户设置使用国内的pip源
mkdir ~/.pip vi ~/.pip/pip.conf [global] index-url = https://pypi.douban.com/simple download_cache = ~/.cache/pip [install] use-mirrors = true mirrors = http://pypi.douban.com/
su - stack $ mkdir ~/.pip $ vi ~/.pip/pip.conf [global] index-url = https://pypi.douban.com/simple download_cache = ~/.cache/pip [install] use-mirrors = true mirrors = http://pypi.douban.com/
cd /opt/stack/devstack vi local.conf [[local|localrc]] GIT_BASE=http://git.trystack.cn NOVNC_REPO=http://git.trystack.cn/kanaka/noVNC.git SPICE_REPO=http://git.trystack.cn/git/spice/spice-html5.git #初次安装设置true,重复安装设置为False #RECLONE=False RECLONE=True MULTI_HOST=true HOST_IP=192.168.18.61 LOGFILE=/opt/stack/logs/stack.sh.log ADMIN_PASSWORD=123456 MYSQL_PASSWORD=123456 RABBIT_PASSWORD=123456 SERVICE_PASSWORD=123456 SERVICE_TOKEN=abcdefghijklmnopqrstuvwxyz disable_service n-net enable_service q-svc enable_service q-agt enable_service q-dhcp enable_service q-l3 enable_service q-meta enable_service q-metering enable_service neutron Q_USE_SECGROUP=True FLOATING_RANGE="192.168.18.0/24" FIXED_RANGE="10.0.0.0/24" Q_FLOATING_ALLOCATION_POOL=start=192.168.18.220,end=192.168.18.230 PUBLIC_NETWORK_GATEWAY="192.168.18.3" Q_L3_ENABLED=True PUBLIC_INTERFACE=enp7s0f0 Q_USE_PROVIDERNET_FOR_PUBLIC=True OVS_PHYSICAL_BRIDGE=br-ex PUBLIC_BRIDGE=br-ex OVS_BRIDGE_MAPPINGS=public:br-ex Q_PLUGIN=ml2 ENABLE_TENANT_VLANS=True LOG_COLOR=True LOGDIR=/opt/stack/logs SCREEN_LOGDIR=$LOGDIR/screen chown -R stack:stack /opt/stack/devstack/local.conf
su - stack cd devstack/ ./stack.sh
中间如果出错
./unstack.sh 后重新安装
还是出错,
./clean.sh 后重新安装
安装完成输出
=========================
DevStack Component Timing
=========================
Total runtime 3375
run_process 15 test_with_retry 6 apt-get-update 11 pip_install 756 osc 237 wait_for_service 25 git_timed 546 dbsync 239 apt-get 361 ========================= This is your host IP address: 192.168.18.61 This is your host IPv6 address: ::1 Horizon is now available at http://192.168.18.61/dashboard Keystone is serving at http://192.168.18.61/identity/ The default users are: admin and demo The password: 123456
同controller节点操作一致:
更新apt源 安装 python-pip 下载devstack 创建stack用户 设置pip的镜像源
编辑local.conf
cd /opt/stack/devstack vi local.conf [[local|localrc]] GIT_BASE=http://git.trystack.cn NOVNC_REPO=http://git.trystack.cn/kanaka/noVNC.git SPICE_REPO=http://git.trystack.cn/git/spice/spice-html5.git RECLONE=False MULTI_HOST=true HOST_IP=192.168.18.62 LOGFILE=/opt/stack/logs/stack.sh.log ADMIN_PASSWORD=123456 MYSQL_PASSWORD=123456 RABBIT_PASSWORD=123456 SERVICE_PASSWORD=123456 SERVICE_TOKEN=abcdefghijklmnopqrstuvwxyz SERVICE_HOST=192.168.18.61 MYSQL_HOST=$SERVICE_HOST RABBIT_HOST=$SERVICE_HOST GLANCE_HOSTPORT=$SERVICE_HOST:9292 Q_HOST=$SERVICE_HOST KEYSTONE_AUTH_HOST=$SERVICE_HOST KEYSTONE_SERVICE_HOST=$SERVICE_HOST ENABLED_SERVICES=n-cpu,q-agt,neutron Q_PLUGIN=ml2 ENABLE_TENANT_VLANS=True NEUTRON_CREATE_INITIAL_NETWORKS=False enable_service placement-api NOVA_VNC_ENABLED=True NOVNCPROXY_URL="http://$SERVICE_HOST:6080/vnc_auto.html" VNCSERVER_LISTEN=$HOST_IP VNCSERVER_PROXYCLIENT_ADDRESS=$VNCSERVER_LISTEN LOG_COLOR=True disable_service tempest
切换到stack用户,执行安装脚本
su - stack
cd devstack/
./stack.sh
安装完成输出
========================= DevStack Component Timing ========================= Total runtime 275 run_process 4 apt-get-update 8 pip_install 109 osc 14 wait_for_service 16 apt-get 28 ========================= This is your host IP address: 192.168.18.62 This is your host IPv6 address: ::1 WARNING: Using lib/neutron-legacy is deprecated, and it will be removed in the future Services are running under systemd unit files. For more information see: https://docs.openstack.org/devstack/latest/systemd.html DevStack Version: pike Change: 73d848772186bf674e12f6253263aed9e164413a Merge "Bump the Cinder LVM backing file size to 24Gb." into stable/pike 2018-04-21 05:10:38 +0000 OS Version: Ubuntu 16.04 xenial
最后,要让计算节点注册在控制节点上运行
root@ubuntu61:/opt/stack/devstack/tools# ./discover_hosts.sh
以上是“devstack如何安装openstack pike”这篇文章的所有内容,感谢各位的阅读!希望分享的内容对大家有帮助,更多相关知识,欢迎关注亿速云行业资讯频道!
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。