openstack ovs实现vlan组网

如果你不相信努力和时光,那么成果就会是第一个选择辜负你的。不要去否定你自己的过去,也不要用你的过去牵扯你现在的努力和对未来的展望。不是因为拥有希望你才去努力,而是去努力了,你才有可能看到希望的光芒。openstack ovs实现vlan组网,希望对大家有帮助,欢迎收藏,转发!站点地址:www.bmabk.com,来源:原文

本文是配置文档,非说明文档,只讲配置,不讲原理。

controller节点:

网卡信息:ens160 外网网卡 ; ens192 数据网卡

openstack ovs实现vlan组网

/etc/neutron/plugins/ml2/ml2_conf.ini配置

openstack ovs实现vlan组网

openstack ovs实现vlan组网

openstack ovs实现vlan组网

openstack ovs实现vlan组网

 

/etc/neutron/plugins/ml2/ml2_conf.ini的所有配置项

[DEFAULT]
[ml2]
type_drivers = flat,vlan,vxlan
tenant_network_types = vlan
mechanism_drivers = openvswitch
[ml2_type_flat]
flat_networks = provider
[ml2_type_geneve]
[ml2_type_gre]
[ml2_type_vlan]
network_vlan_ranges = default:3001:4000
[ml2_type_vxlan]
vni_ranges = 1:1000
[securitygroup]
enable_ipset = true
enable_security_group = False
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver

 

 

 /etc/neutron/plugins/ml2/openvswitch_agent.ini 

下图是从vxlan模式修改过来的配置。注意enable_tunneling=false

openstack ovs实现vlan组网

 

直接配置成vlan模式

openstack ovs实现vlan组网

 

/etc/neutron/plugins/ml2/openvswitch_agent.ini 

[DEFAULT]
[agent]
tunnel_types = vxlan
vxlan_udp_port = 4789
l2_population = False
prevent_arp_spoofing = False
arp_responder = False
[ovs]
bridge_mappings = external:br-ex,default:br-eth1
local_ip = 10.0.10.150
tunnel_bridge = br-tun
integration_bridge = br-int
tunnel_id_ranges = 1:1000
tenant_network_type = vxlan
enable_tunneling = false
tunnel_types = vxlan
[securitygroup]
enable_security_group = False
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
[xenapi]

 

 

修改好所有的配置后创建网桥,重启服务。原理见vxlan分析。

ovs-vsctl add-br br-eth1

ovs-vsctl add-port br-eth1 ens192

service neutron-openvswitch-agent restart

 

compute节点:

网卡信息:ens160 外网网卡;ens192 管理网卡

openstack ovs实现vlan组网

 

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

openstack ovs实现vlan组网

openstack ovs实现vlan组网

 

/etc/neutron/plugins/ml2/openvswitch_agent.ini 

openstack ovs实现vlan组网

openstack ovs实现vlan组网

 

计算节点同样要创建br-eth1网桥

ovs-vsctl add-br br-eth1 

ovs-vsctl add-port br-eth1 ens192

service neutron-openvswitch-agent restart

 

 

 

/etc/neutron/plugins/ml2/openvswitch_agent.ini 
openvswitch
[DEFAULT]
[agent]
tunnel_types = vxlan
l2_population = False
prevent_arp_spoofing = False
arp_responder = False
vxlan_udp_port = 4789
[ovs]
bridge_mappings = default:br-eth1
local_ip = 10.0.10.151
tunnel_type = vlan
tunnel_bridge = br-tun
integration_bridge = br-int
tunnel_id_ranges = 1:1000
tenant_network_type = vxlan
enable_tunneling = false
[securitygroup]
enable_ipset = True
enable_security_group = False
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver
[xenapi]
/etc/neutron/plugins/ml2/ml2_conf.ini
[DEFAULT]
[ml2]
type_drivers = flat,vlan,vxlan
tenant_network_types = vlan
mechanism_drivers = openvswitch
[ml2_type_flat]
[ml2_type_geneve]
[ml2_type_gre]
[ml2_type_vlan]
network_vlan_ranges = default:3001:4000
[ml2_type_vxlan]
vni_ranges = 1:1000
vxlan_group = <None>
[securitygroup]
enable_security_group = False
enable_ipset = True
firewall_driver = neutron.agent.linux.iptables_firewall.OVSHybridIptablesFirewallDriver

 

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 举报,一经查实,本站将立刻删除。

文章由极客之音整理,本文链接:https://www.bmabk.com/index.php/post/194312.html

(0)
小半的头像小半

相关推荐

极客之音——专业性很强的中文编程技术网站,欢迎收藏到浏览器,订阅我们!