一、base节点设置

mysql -u root -proot

CREATE DATABASE neutron;

GRANT ALL PRIVILEGES ON neutron.* TO 'neutron'@'localhost' IDENTIFIED BY 'NEUTRON_DBPASS';

GRANT ALL PRIVILEGES ON neutron.* TO 'neutron'@'%' IDENTIFIED BY 'NEUTRON_DBPASS';

二、 ctrl节点设置

#运行环境变量

. admin-openrc

#创建neutron用户并添加角色

openstack user create --domain default --password NEUTRON_PASS neutron

openstack role add --project service --user neutron admin

#创建neutron服务并设置endpoint

openstack service create --name neutron --description "OpenStack Networking" network

openstack endpoint create --region RegionOne network public http://ctrl.test.com:9696

openstack endpoint create --region RegionOne network internal http://ctrl.test.com:9696

openstack endpoint create --region RegionOne network admin http://ctrl.test.com:9696

#安装neutron软件

yum install \

openstack-neutron \

openstack-neutron-ml2 \

openstack-neutron-linuxbridge \

ebtables -y

#编辑neutron配置文件

vim /etc/neutron/neutron.conf

[database]
connection = mysql+pymysql://neutron:NEUTRON_DBPASS@base.test.com/neutron [DEFAULT]
core_plugin = ml2
service_plugins =
#service_plugins = router
#allow_overlapping_ips = true
transport_url = rabbit://openstack:RABBIT_PASS@base.test.com
auth_strategy = keystone
notify_nova_on_port_status_changes = true
notify_nova_on_port_data_changes = true [keystone_authtoken]
auth_uri = http://ctrl.test.com:5000
auth_url = http://ctrl.test.com:35357
memcached_servers = base.test.com:
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = NEUTRON_PASS [nova]
auth_url = http://ctrl.test.com:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = nova
password = NOVA_PASS [oslo_concurrency]
lock_path = /var/lib/neutron/tmp

#编辑ml2配置文件

vim /etc/neutron/plugins/ml2/ml2_conf.ini

[ml2]
type_drivers = flat,vlan,gre,vxlan,geneve
#type_drivers = flat,vlan,vxlan
tenant_network_types = flat,vlan,gre,vxlan,geneve
#tenant_network_types = vxlan
mechanism_drivers = linuxbridge
#mechanism_drivers = linuxbridge,l2population
extension_drivers = port_security [ml2_type_flat]
flat_networks = provider [securitygroup]
enable_ipset = true #[ml2_type_vxlan]
#vni_ranges = :

#编辑linuxbridge_agent配置文件

vim /etc/neutron/plugins/ml2/linuxbridge_agent.ini

[linux_bridge]
physical_interface_mappings = provider:eth1 [vxlan]
enable_vxlan = false
#enable_vxlan = true
#local_ip = 172.16.2.52
#l2_population = true [securitygroup]
enable_security_group = true
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver

#编辑l3配置文件

#vim /etc/neutron/l3_agent.ini

[DEFAULT]
#interface_driver = linuxbridge

#编辑dhcp配置文件

vim /etc/neutron/dhcp_agent.ini

[DEFAULT]
interface_driver = linuxbridge
dhcp_driver = neutron.agent.linux.dhcp.Dnsmasq
enable_isolated_metadata = true

#编辑metadata配置文件

vim /etc/neutron/metadata_agent.ini

[DEFAULT]
nova_metadata_host =ctrl.test.com
metadata_proxy_shared_secret = METADATA_SECRET

#编辑Nova配置文件

vim /etc/nova/nova.conf

[neutron]
url = http://ctrl.test.com:9696
auth_url = http://ctrl.test.com:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = NEUTRON_PASS
service_metadata_proxy = true
metadata_proxy_shared_secret = METADATA_SECRET

#创建软连接

ln -s /etc/neutron/plugins/ml2/ml2_conf.ini /etc/neutron/plugin.ini

#初始化数据库

su -s /bin/sh -c "neutron-db-manage --config-file /etc/neutron/neutron.conf \

--config-file /etc/neutron/plugins/ml2/ml2_conf.ini upgrade head" neutron

#启动服务

systemctl restart openstack-nova-api.service

systemctl restart neutron-server.service \

neutron-linuxbridge-agent.service \

neutron-dhcp-agent.service \

neutron-metadata-agent.service

systemctl enable neutron-server.service \

neutron-linuxbridge-agent.service \

neutron-dhcp-agent.service \

neutron-metadata-agent.service

#systemctl restart neutron-l3-agent.service

#systemctl enable neutron-l3-agent.service

#验证(计算节点配置完成再验证)

. admin-openrc

openstack extension list --network

openstack network agent list

三、 com计算节点配置

#安装软件

yum install openstack-neutron-linuxbridge ebtables ipset -y

#编辑neutron配置文件

vim /etc/neutron/neutron.conf

[DEFAULT]
transport_url = rabbit://openstack:RABBIT_PASS@base.test.com
auth_strategy = keystone [keystone_authtoken]
auth_uri = http://ctrl.test.com:5000
auth_url = http://ctrl.test.com:35357
memcached_servers = base.test.com:
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = NEUTRON_PASS [oslo_concurrency]
lock_path = /var/lib/neutron/tmp

#编辑桥接配置文件

vim /etc/neutron/plugins/ml2/linuxbridge_agent.ini

[linux_bridge]
physical_interface_mappings = provider:eth0 [vxlan]
enable_vxlan = false
#enable_vxlan = true
#local_ip = 172.16.2.53
#l2_population = true [securitygroup]
enable_security_group = true
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver

#编辑Nova配置文件

vim /etc/nova/nova.conf

[neutron]
url = http://ctrl.test.com:9696
auth_url = http://ctrl.test.com:35357
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = NEUTRON_PASS

#开启服务

systemctl restart openstack-nova-compute.service

systemctl restart neutron-linuxbridge-agent.service

systemctl enable neutron-linuxbridge-agent.service

注:配置文件中注释部分配置文件为创建L3路由网络使用的配置信息。未注释的配置信息为交换机网络。后续创建网络根据需要进行开启。注意,相同项保留一项即可。

openstack搭建之-neutron配置(11)的更多相关文章

  1. openstack搭建之-cinder配置(12)

    一. base节点配置 mysql -u root -proot CREATE DATABASE cinder; GRANT ALL PRIVILEGES ON cinder.* TO 'cinder ...

  2. openstack搭建之-nova配置(10)

    一. base节点设置数据库 mysql -u root -proot CREATE DATABASE nova_api; CREATE DATABASE nova; CREATE DATABASE ...

  3. openstack搭建之-glance配置(9)

    一. base节点配置 #设置数据库,创建glance数据库,并设置权限 mysql -u root -proot CREATE DATABASE glance; GRANT ALL PRIVILEG ...

  4. openstack搭建之-keystone配置(8)

    一. Base Node配置 mysql -uroot -proot CREATE DATABASE keystone GRANT ALL PRIVILEGES ON keystone.* to 'k ...

  5. openstack搭建之-horizon配置(14)

    一.ctrl控制节点安装horizon #安装软件yum install openstack-dashboard -y vim /etc/openstack-dashboard/local_setti ...

  6. OpenStack-Ocata版+CentOS7.6 云平台环境搭建 —7.网络服务Neutron配置

    网络服务Neutron本章节结束如何安装并配置网络服务(neutron)采用:ref:`provider networks <network1>`或:ref:`self-service n ...

  7. openstack网络(neutron)模式之GRE的基本原理

    neutron网络目的是为OpenStack云更灵活的划分网络,在多租户的环境下提供给每个租户独立的网络环境. neutron混合实施了第二层的VLAN和第三层的路由服务,它可为支持的网络提供防火墙, ...

  8. Openstack搭建(流水账)

    Openstack管理三大资源:1.网络资源2.计算资源3.存储资源 Keystone 做服务注册 Glance 提供镜像服务 Nova 提供计算服务 Nova scheduler决策虚拟主机创建在哪 ...

  9. OpenStack 安装:neutron服务

    在上一篇中介绍了Nova的安装配置,这一篇介绍neutron 首先,创建neutron用户并设置密码为neutron [root@linux-node1 ~]# openstack user crea ...

随机推荐

  1. 第31章 日志 - Identity Server 4 中文文档(v1.0.0)

    IdentityServer使用ASP.NET Core提供的标准日志记录工具.Microsoft文档有一个很好的介绍和内置日志记录提供程序的描述. 我们大致遵循Microsoft使用日志级别的指导原 ...

  2. .net core EFCore CodeFirst 迁移出现错误【No project was found. Change the current working directory or use the --project option. 】

    PM> dotnet ef Migrations add Init No project was found. Change the current working directory or u ...

  3. C#如何发送邮件

    准备工作: 1.开启Smtp服务 2.如果邮件设置中有“客户端授权码"(以163邮箱为例,有的邮箱不需要),需要开启“客户端授权码" 发送邮件: using (MailMessag ...

  4. 学JAVA的第二天,静态网站制作,脑阔一点疼

    先从下载apache-tomcat-9.0.17开始 在下边这个网站下载,下边一步步来 下面删除的这些是暂时用不上的,先吧它删除了,因为会拖慢启动速度 下边把ROOT里边除WEB-INF外的全不删除了 ...

  5. nginx系列3:搭建一个静态资源web服务器

    搭建静态资源web服务器 1,创建静态页面 在nginx的安装目录(/usr/local/nginx)下创建文件夹webapplications/helloworld,然后创建一个名为index.ht ...

  6. 浏览器登录Dynamics 365 CE没毛病,程序连接却报错。

    摘要: 微软动态CRM专家罗勇 ,回复308或者20190308可方便获取本文,同时可以在第一间得到我发布的最新博文信息,follow me!我的网站是 www.luoyong.me . 今天我做实验 ...

  7. QT之Http请求

    今天我们介绍一下QT的http请求,这里有post和get两种方式 一.post请求方式:参数分为网址和具体请求值两个部分,有时候还需要设置头信息,看具体情况定 void MainWindow::se ...

  8. Linux简单配置SendMail发送邮件

    本文简单整理了一下如何在Linux服务器上安装.配置SendMail发送邮件的步骤,此文不是配置邮件服务器,具体测试环境为CentOS Linux release 7.2.1511 (Core) ,如 ...

  9. webmagic 基本的方法

    WebMagic的结构分为Downloader.PageProcessor.Scheduler.Pipeline四大组件,并由Spider将它们彼此组织起来.这四大组件对应爬虫生命周期中的下载.处理. ...

  10. Linux内存描述之内存区域zone--Linux内存管理(三)

    1 内存管理域zone 为了支持NUMA模型,也即CPU对不同内存单元的访问时间可能不同,此时系统的物理内存被划分为几个节点(node), 一个node对应一个内存簇bank,即每个内存簇被认为是一个 ...