Centos0S7手动安装OpenStack Pike版--(四)

#Configure Nova
mysql -uroot -ppasswd123 -e "CREATE DATABASE nova_api"
mysql -uroot -ppasswd123 -e "CREATE DATABASE nova"
mysql -uroot -ppasswd123 -e "CREATE DATABASE nova_cell0"

mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova_api. TO ‘nova‘@‘localhost‘ IDENTIFIED BY ‘passwd123‘"
mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova_api.
TO ‘nova‘@‘%‘ IDENTIFIED BY ‘passwd123‘"
mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova. TO ‘nova‘@‘localhost‘ IDENTIFIED BY ‘passwd123‘"
mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova.
TO ‘nova‘@‘%‘ IDENTIFIED BY ‘passwd123‘"
mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova_cell0. TO ‘nova‘@‘localhost‘ IDENTIFIED BY ‘passwd123‘"
mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON nova_cell0.
TO ‘nova‘@‘%‘ IDENTIFIED BY ‘passwd123‘"

source admin-openrc
openstack user create --domain default --password passwd123 nova
openstack role add --project service --user nova admin
openstack service create --name nova --description "OpenStack Compute" compute

openstack endpoint create --region RegionOne compute public http://controller:8774/v2.1
openstack endpoint create --region RegionOne compute internal http://controller:8774/v2.1
openstack endpoint create --region RegionOne compute admin http://controller:8774/v2.1

openstack user create --domain default --password paswd123 placement
openstack role add --project service --user placement admin
openstack service create --name placement --description "Placement API" placement

openstack endpoint create --region RegionOne placement public http://controller:8778
openstack endpoint create --region RegionOne placement internal http://controller:8778
openstack endpoint create --region RegionOne placement admin http://controller:8778

Edit the /etc/nova/nova.conf
openstack-config --set /etc/nova/nova.conf DEFAULT enabled_apis osapi_compute,metadata

openstack-config --set /etc/nova/nova.conf api_database connection mysql+pymysql://nova:[email protected]/nova_api
openstack-config --set /etc/nova/nova.conf database connection mysql+pymysql://nova:[email protected]/nova

openstack-config --set /etc/nova/nova.conf DEFAULT transport_url rabbit://openstack:[email protected]
openstack-config --set /etc/nova/nova.conf api auth_strategy keystone
openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_uri http://controller:5000
openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_url http://controller:35357
openstack-config --set /etc/nova/nova.conf keystone_authtoken memcached_servers controller:11211
openstack-config --set /etc/nova/nova.conf keystone_authtoken auth_type password
openstack-config --set /etc/nova/nova.conf keystone_authtoken project_domain_name default
openstack-config --set /etc/nova/nova.conf keystone_authtoken user_domain_name default
openstack-config --set /etc/nova/nova.conf keystone_authtoken project_name service
openstack-config --set /etc/nova/nova.conf keystone_authtoken username nova
openstack-config --set /etc/nova/nova.conf keystone_authtoken password passwd123

openstack-config --set /etc/nova/nova.conf DEFAULT my_ip 192.168.137.145
openstack-config --set /etc/nova/nova.conf DEFAULT use_neutron True
openstack-config --set /etc/nova/nova.conf DEFAULT firewall_driver nova.virt.firewall.NoopFirewallDriver

openstack-config --set /etc/nova/nova.conf vnc enabled true
openstack-config --set /etc/nova/nova.conf vnc vncserver_listen 192.168.137.145
openstack-config --set /etc/nova/nova.conf vnc vncserver_proxyclient_address 192.168.137.145

openstack-config --set /etc/nova/nova.conf glance api_servers http://controller:9292

openstack-config --set /etc/nova/nova.conf oslo_concurrency lock_path /var/lib/nova/tmp

openstack-config --set /etc/nova/nova.conf placement os_region_name RegionOne
openstack-config --set /etc/nova/nova.conf placement project_domain_name Default
openstack-config --set /etc/nova/nova.conf placement project_name service
openstack-config --set /etc/nova/nova.conf placement auth_type password
openstack-config --set /etc/nova/nova.conf placement user_domain_name Default
openstack-config --set /etc/nova/nova.conf placement auth_url http://controller:35357/v3
openstack-config --set /etc/nova/nova.conf placement username placement
openstack-config --set /etc/nova/nova.conf placement password passwd123

vim /etc/httpd/conf.d/00-nova-placement-api.conf
<Directory /usr/bin>
<IfVersion >= 2.4>
Require all granted
</IfVersion>
<IfVersion < 2.4>
Order allow,deny
Allow from all
</IfVersion>
</Directory>

systemctl restart httpd
systemctl status httpd

su -s /bin/sh -c "nova-manage api_db sync" nova
su -s /bin/sh -c "nova-manage cell_v2 map_cell0" nova
su -s /bin/sh -c "nova-manage cell_v2 create_cell --name=cell1 --verbose" nova
su -s /bin/sh -c "nova-manage db sync" nova
nova-manage cell_v2 list_cells

systemctl enable openstack-nova-api.service openstack-nova-consoleauth.service openstack-nova-scheduler.service \
openstack-nova-conductor.service openstack-nova-novncproxy.service
systemctl start openstack-nova-api.service openstack-nova-consoleauth.service openstack-nova-scheduler.service \
openstack-nova-conductor.service openstack-nova-novncproxy.service
systemctl status openstack-nova-api.service openstack-nova-consoleauth.service openstack-nova-scheduler.service \
openstack-nova-conductor.service openstack-nova-novncproxy.service

openstack service list

原文地址:http://blog.51cto.com/andyliu/2069165

时间: 2024-10-27 13:37:26

Centos0S7手动安装OpenStack Pike版--(四)的相关文章

Centos0S7手动安装OpenStack Pike版--(二)

#Configure Keystonemysql -uroot -ppasswd123 -e "CREATE DATABASE keystone"mysql -uroot -ppasswd123 -e "GRANT ALL PRIVILEGES ON keystone. TO 'keystone'@'localhost' IDENTIFIED BY 'passwd123'"mysql -uroot -ppasswd123 -e "GRANT ALL PRI

OpenStack pike版 安装openstack服务(4) 续安装openstack服务(3) &nbsp; &nbsp;

Compute service overview 计算服务概述 OpenStack用于对主机的计算和管理云计算系统.OpenStack的计算是一个基础设施即服务(IaaS)系统的一个重要组成部分.主要模块是用python实现的. OpenStack计算与OpenStack身份验证交互用来完成认证:OpenStack镜像服务用于磁盘和服务器镜像:用户和管理接口为OpenStack Dashboard.镜像访问受到项目和用户的限制,每个项目的配额是有限的(例如,实例的数量).OpenStack计算可

CentOS7.2非HA分布式部署Openstack Pike版 (实验)

部署环境 一.组网拓扑 二.设备配置 笔记本:联想L440处理器:i3-4000M 2.40GHz内存:12G虚拟机软件:VMware? Workstation 12 Pro(12.5.2 build-4638234) 三.虚拟机配置 Controller节点:系统:CentOS7.2 64位(最小化安装)处理器:4核内存:4G硬盘:100G网卡:3块 Compute节点:系统:CentOS7.2 64位(最小化安装)处理器:4核内存:4G硬盘:100G网卡:3块 Cinder节点:系统:Cen

Centos7手动安装OpenStack Mitaka版本--基本环境安装

Centos7手动安装OpenStack Mitaka版本--第一节:基本环境配置 一台控制节点 controller_ip=10.1.1.160 controller_ip2=192.168.13.147 一台计算节点 compute_ip=10.1.1.162 compute_ip2=192.168.13.144 hosts文件配置 [[email protected] ~]# cat /etc/hosts 127.0.0.1   localhost localhost.localdomai

OpenStack pike版 安装openstack服务(3) 续基本环境部署(2)

安装openstack服务 所有openstack服务的安装指南链接:https://docs.openstack.org/pike/install/ 最小化部署,需要按照下面指定的顺序安装以下服务: Identity service – keystone installation for Pike Image service – glance installation for Pike Compute service – nova installation for Pike Networkin

OpenStack pike版 基本环境部署(2) 续案例架构(1)

续案例架构(1) 环境准备工作: 按照以下规划配置各主机IP地址及主机名称 # controller 10.0.0.11       controller # compute1 10.0.0.31       compute1 # block1 10.0.0.41       block1 # object1 10.0.0.51       object1 # object2 10.0.0.52       object2 做名称解析: 编辑/etc/hosts文件,将以上内容写入即可. 关闭所

OpenStack pike版 安装openstack服务(5) 续安装openstack服务(4)

网络服务简介 OpenStack网络(neutron)允许您创建和将其他OpenStack服务管理的接口设备附加到网络中.插件可以适应不同的网络设备和软件,为OpenStack的架构和部署提供灵活性. 它包括以下组件: neutron-server:接受并将API请求路由到相应的OpenStack网络插件以进行操作. OpenStack Networking plug-ins and agent:即插即用端口,创建网络或者子网,提供IP地址.这些插件和代理根据特定云使用的供应商和技术而有所不同.

初识OpenStack Pike版

Preface 前言 OpenStack系统由几个单独安装的关键服务组成.这些服务根据您的云需求一起工作,包括计算.身份验证.网络.镜像.块存储.对象存储.监控.编排和数据库服务.您可以分别安装这些项目中的任何一个,并将它们独立配置或安装到一起. OpenStack项目是一个开源云计算平台,适用于所有类型的云,其目的是实现简单.可伸缩性强.功能丰富.来自世界各地的开发者和云计算技术人员创建OpenStack项目. OpenStack基础架构即服务(IaaS)提供了一种通过一组相互关联的服务解决方

OpenStack pike版 案例架构(1)

案例架构 至少需要两个节点(主机)来启动基本虚拟机或实例.可选的服务,如块存储和对象存储需要额外的节点. Controller 控制节点 控制节点运行: Identity service 身份验证服务 Image service  镜像服务 management portions of Compute 计算管理部分 management portion of Networking  网络管理部分 various Networking agents      各种网络代理 Dashboard