9 Openstack-Ussuri-Neutron计算节点部署-ubuntu1804

Nova具体功能如下:
1 Neutron 为整个 OpenStack 环境提供网络支持,包括二层交换,三层路由,负载均衡,防火墙和 VPN 等。
2 Neutron 提供了一个灵活的框架,通过配置,无论是开源还是商业软件都可以被用来实现这些功能。

9.1 部署与配置neutron client - compute162

#安装包

apt install neutron-linuxbridge-agent -y

#备份neutron配置

cp /etc/neutron/neutron.conf /etc/neutron/neutron.conf.bak
egrep -v "^$|^#" /etc/neutron/neutron.conf.bak >/etc/neutron/neutron.conf

#配置neutron配置文件,在对应项底下增加以下字段
#vim /etc/neutron/neutron.conf

[DEFAULT]
# ...
auth_strategy = keystone
transport_url = rabbit://rabbitmq:rabbitmq.123@controller160:5672/

[keystone_authtoken]
# ...
www_authenticate_uri = http://controller160:5000
auth_url = http://controller160:5000
memcached_servers = controller160:11211
auth_type = password
project_domain_name = Default
user_domain_name = Default
project_name = service
username = neutron
password = neutron.123

[oslo_concurrency]
lock_path = /var/lib/neutron/tmp

#修改nova配置文件,在对应项底下增加以下字段
#vim /etc/nova/nova.conf

[neutron]
# ...
auth_url = http://controller160:5000
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = neutron.123

#重启nova-compute服务

systemctl restart nova-compute

#备份linuxbridge_agent.ini配置

cp /etc/neutron/plugins/ml2/linuxbridge_agent.ini /etc/neutron/plugins/ml2/linuxbridge_agent.ini.bak
egrep -v "^$|^#" /etc/neutron/plugins/ml2/linuxbridge_agent.ini.bak >/etc/neutron/plugins/ml2/linuxbridge_agent.ini

#配置linuxbridge_agent.ini文件,在对应项底下增加以下字段
#vim /etc/neutron/plugins/ml2/linuxbridge_agent.ini

[linux_bridge]
physical_interface_mappings = provider:eth1

[vxlan]
enable_vxlan = true
local_ip = 172.16.3.162
l2_population = true

[securitygroup]
# ...
enable_security_group = true
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver

#确保您的Linux操作系统内核支持网桥过滤器,通过验证所有下列sysctl值设置为1:

cat >> /etc/sysctl.conf <<EOF
net.bridge.bridge-nf-call-iptables = 1
net.bridge.bridge-nf-call-ip6tables = 1
EOF
sysctl -p /etc/sysctl.conf

#重启neutron-agent服务,并配置开机启动:

systemctl enable neutron-linuxbridge-agent
systemctl restart neutron-linuxbridge-agent
systemctl status neutron-linuxbridge-agent

9.2 neutron服务验证

#加载管理凭证

source adminrc.sh

#执行network agent 检查

openstack network agent list

#输出

 +--------------------------------------+--------------------+------------+-------------------+-------+-------+---------------------------+
| ID                                   | Agent Type         | Host       | Availability Zone | Alive | State | Binary                    |
+--------------------------------------+--------------------+------------+-------------------+-------+-------+---------------------------+
| 0475cec8-24b0-4540-92ce-603e6add0be1 | L3 agent           | neutron161 | nova              | :-)   | UP    | neutron-l3-agent          |
| 0edfd3aa-6278-4749-8e51-6aeb19cdf41a | Linux bridge agent | neutron161 | None              | :-)   | UP    | neutron-linuxbridge-agent |
| 1ddf6f7f-5c3b-4647-8e53-62fa7fafd067 | Metadata agent     | neutron161 | None              | :-)   | UP    | neutron-metadata-agent    |
| 27c9e1f7-4d0d-4bab-a7f2-9f43934e3871 | Linux bridge agent | compute162 | None              | :-)   | UP    | neutron-linuxbridge-agent |
| cd323219-dd6b-486b-86c4-241c02a5588d | DHCP agent         | neutron161 | nova              | :-)   | UP    | neutron-dhcp-agent        |
+--------------------------------------+--------------------+------------+-------------------+-------+-------+---------------------------+

至此,neutron计算节点服务已部署完毕,如有问题请联系我改正,感激不尽!

9.x 部署过程遇到的问题汇总

eg1. 

你可能感兴趣的:(9 Openstack-Ussuri-Neutron计算节点部署-ubuntu1804)