理解 neutron(15):Neutron Linux Bridge + VLAN/VXLAN 虚拟网络
?
學(xué)習(xí) Neutron 系列文章:
(1)Neutron 所實(shí)現(xiàn)的虛擬化網(wǎng)絡(luò)
(2)Neutron OpenvSwitch + VLAN 虛擬網(wǎng)絡(luò)
(3)Neutron?OpenvSwitch + GRE/VxLAN 虛擬網(wǎng)絡(luò)
(4)Neutron OVS OpenFlow 流表 和 L2 Population
(5)Neutron DHCP Agent
(6)Neutron L3 Agent??
(7)Neutron LBaas
(8)Neutron Security Group
(9)Neutron?FWaas?和?Nova Security Group
(10)Neutron?VPNaas
(11)Neutron DVR
(12)Neutron VRRP
(13)High Availability (HA)
(14)Linux bridge + VXLAN
(15)Neutron Linux Bridge + VLAN/VXLAN 虛擬網(wǎng)絡(luò)
?
雖然大部分的OpenStack 部署環(huán)境中,都會(huì)使用 Open vSwitch 來(lái)作為虛擬交換機(jī)來(lái)實(shí)現(xiàn)二層網(wǎng)絡(luò)功能,但是Neutron 仍然支持使用 Linux bridge 作為虛擬交換機(jī)來(lái)實(shí)現(xiàn)二層網(wǎng)絡(luò)。本文就此做些分析和說(shuō)明。?
同時(shí)要指出的是,OpenStack 官方已經(jīng)把 linux bridge 實(shí)現(xiàn)標(biāo)記為 legacy 的了,文檔從 2016 年后也沒(méi)怎么更新了。這是因?yàn)?#xff0c;linux bridge 和 OVS 相比,只支持基本的網(wǎng)絡(luò)功能即二層交換,但不支持VLAN 標(biāo)簽和隧道。因此,linux bridge agent 利用linux 內(nèi)核功能(VLAN 子接口和 VXLAN 接口)來(lái)實(shí)現(xiàn)VLAN 標(biāo)簽和隧道。
?
?1. 測(cè)試環(huán)境
以下面的環(huán)境為例(網(wǎng)絡(luò)節(jié)點(diǎn)上):
(1)linux bridge
root@controller:/home/sammy# brctl show bridge name bridge id STP enabled interfaces brq85925305-b4 8000.563534c8d02d no tap0bb8efeb-10tap798c87d1-a2vxlan-25 brq96609bfa-0e 8000.0050569c4d94 no ens224tap60dbdc2f-a0 brq971ffda2-e5 8000.a6acb08e4fd6 no tapb1eaae00-e5tapf70543dd-0fvxlan-10(2)OpenStack 網(wǎng)絡(luò)和 network namespace:
root@controller:/home/sammy# neutron net-list +--------------------------------------+---------+-----------------------------------------------------+ | id | name | subnets | +--------------------------------------+---------+-----------------------------------------------------+ | 96609bfa-0e22-4bb7-8dba-6ef532ea6076 | extnet | afa7d205-3026-439f-aca7-295a9f9b2a71 10.62.227.0/24 | | 971ffda2-e567-40a0-a2c8-b31a577fd4d3 | appnet | 4c68eacb-bf3e-408a-a941-94e93eddb22b 11.0.0.0/24 | | | | 3d596991-de8f-4ae4-8913-89426a8abbd7 10.0.0.0/24 | | 85925305-b477-4cc6-9654-67d9bf1e7cd8 | appnet2 | 4575c7f1-7f08-4917-9904-ec65af38619b 20.0.0.0/24 | +--------------------------------------+---------+-----------------------------------------------------+ root@controller:/home/sammy# ip netns qdhcp-85925305-b477-4cc6-9654-67d9bf1e7cd8 (id: 2) qdhcp-971ffda2-e567-40a0-a2c8-b31a577fd4d3 (id: 1) qrouter-39a77439-8a28-49c1-bf97-ac931510631b (id: 0)(3)示意圖:
(4)說(shuō)明:
- qdhcp 和 qrouter 都是 linux network namespace 實(shí)例
- qdhcp network namespace 的數(shù)量等于啟用了 DHCP 的 Neutron network 的數(shù)量。
- 當(dāng)一個(gè) network 中存在至少一個(gè) subnet 啟用了 DHCP 之后,會(huì)有一個(gè) qdhcp network namespace 被創(chuàng)建出來(lái);
- 當(dāng)一個(gè) network 中多個(gè) subnet 啟用了 DHCP 時(shí),它們共用一個(gè) qdhcp,以及 dnsmasq。
- 其 name 使用 network id,比如?qdhcp-85925305-b477-4cc6-9654-67d9bf1e7cd8
- qrouter network namespace 的數(shù)目等于 router 的數(shù)目,也就是說(shuō),系統(tǒng)中一共有幾個(gè) router,那么就存在幾個(gè) qrouter network namespace
- brq linux bridge 的數(shù)目等于 neutron network 的數(shù)目,其 name 是 network id 的前幾位,比如?brq96609bfa-0e
- 一個(gè) network 的 qdhcp network namespace 和其 brq linux bridge 一定有連接
- qrouter 之內(nèi)的 network interface 分兩種,一種是 qr 開(kāi)頭的,每個(gè)連接到 router 之上的 subnet 都有一個(gè);還有一個(gè)是 qg,每個(gè)連接到 router 的 external subnetwork 有一個(gè)
- qrouter 的每個(gè) network interface 都通過(guò) veth 連接到所在網(wǎng)絡(luò)的 qbr linux bridge 上
- qbr linux bridge 連連接兩種物理設(shè)備,一種是 vxlan interface,每個(gè) tenant network 有一個(gè),另一種是在 physical network 對(duì)應(yīng)的物理網(wǎng)卡上創(chuàng)建的子接口(sub-interface)
- 對(duì)于 physical network 的 qbr 來(lái)說(shuō),用戶可以指定它,并且在linuxbridge_agent.ini 中通過(guò)?bridge_mappings = List of <physical_network>:<physical_bridge> 進(jìn)行配置;也可以不指定,此時(shí) agent 會(huì)創(chuàng)建它。當(dāng)同時(shí)配置了 physical bridge 和 physical interface 時(shí),前者優(yōu)先。
如果 external network 中有多個(gè) subnet 的話:
(1)每個(gè) qrouter 只允許有一個(gè)?External Gateway,也就是說(shuō)它只有一個(gè) qg network interface。當(dāng) external network 添加多個(gè) subnet 之后,只有第一個(gè)被當(dāng)作 external subnet,其余的都會(huì)被當(dāng)作 internal subnet。
(2)在 qrouter 的路由表之中,
root@controller:/home/sammy# ip netns exec qrouter-39a77439-8a28-49c1-bf97-ac931510631b route Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default 10.62.227.1 0.0.0.0 UG 0 0 0 qg-e09fce07-cd 10.0.0.0 * 255.255.255.0 U 0 0 0 qr-b1eaae00-e5 10.62.227.0 * 255.255.255.0 U 0 0 0 qg-e09fce07-cd 10.62.228.0 * 255.255.255.0 U 0 0 0 qg-e09fce07-cd 10.62.228.0 * 255.255.255.0 U 0 0 0 qr-124ff148-b7 11.0.0.0 * 255.255.255.0 U 0 0 0 qr-16d9b0cc-38 20.0.0.0 * 255.255.255.0 U 0 0 0 qr-0bb8efeb-10?
2. linux-bridge-agent 工作過(guò)程分析
(1)linuxbridge-agent 會(huì)啟動(dòng)一個(gè)循環(huán),不斷掃描上面紅框中的 tap 設(shè)備
def daemon_loop(self): ...while True:start = time.time() . ..device_info = self.scan_devices(previous=device_info, sync=sync)sync = Falseif (self._device_info_has_changes(device_info)or self.sg_agent.firewall_refresh_needed()):LOG.debug("Agent loop found changes! %s", device_info)try:sync = self.process_network_devices(device_info)except Exception:LOG.exception(_LE("Error in agent loop. Devices info: %s"),device_info)sync = True這是它首先找到的 devices:
(Pdb) p bridge_lib.get_bridge_names()
['brq85925305-b4', 'virbr0', 'brq971ffda2-e5', 'virbr0-nic', 'tapb1eaae00-e5', 'tapf70543dd-0f', 'vxlan-25', 'vxlan-10', 'tap0bb8efeb-10', 'lo', 'tap60dbdc2f-a0', 'tap795e6e86-94', 'ens224', 'ens192', 'ens160', 'tap798c87d1-a2']
然后過(guò)濾出 tap 設(shè)備:
get_all_devices()->set(['tap0bb8efeb-10', 'tap60dbdc2f-a0', 'tap795e6e86-94', 'tap798c87d1-a2', 'tapb1eaae00-e5', 'tapf70543dd-0f'])
(2)根據(jù) previous 中保存的歷史數(shù)據(jù),再接合服務(wù)器端和本地更新時(shí)間,計(jì)算出需要更新的tap設(shè)備列表:
{'current': set(['tapf70543dd-0f', 'tap60dbdc2f-a0', 'tapb1eaae00-e5', 'tap795e6e86-94', 'tap0bb8efeb-10', 'tap798c87d1-a2']), 'timestamps': {'tapf70543dd-0f': 1476956816.672447, 'tap60dbdc2f-a0': None, 'tapb1eaae00-e5': 1476956816.672447, 'tap795e6e86-94': None, 'tap0bb8efeb-10': 1476689797.1378036, 'tap798c87d1-a2': 1476689701.1349163}, 'removed': set([]), 'added': set(['tapf70543dd-0f', 'tap60dbdc2f-a0', 'tapb1eaae00-e5', 'tap795e6e86-94', 'tap0bb8efeb-10', 'tap798c87d1-a2']), 'updated': set([])}??(3) 通過(guò) RPC 獲取 tap 設(shè)備的詳細(xì)信息
(Pdb) p devices set(['tapf70543dd-0f', 'tap60dbdc2f-a0', 'tapb1eaae00-e5', 'tap795e6e86-94', 'tap798c87d1-a2', 'tap0bb8efeb-10'])devices_details_list = self.plugin_rpc.get_devices_details_list(Pdb) p devices_details_list [{u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'971ffda2-e567-40a0-a2c8-b31a577fd4d3', u'segmentation_id': 10, u'device_owner': u'network:dhcp', u'physical_network': None, u'mac_address': u'fa:16:3e:5c:bf:11', u'device': u'tapf70543dd-0f', u'port_security_enabled': False, u'port_id': u'f70543dd-0f1b-4e1d-93c7-33f4f3d7a709', u'fixed_ips': [{u'subnet_id': u'3d596991-de8f-4ae4-8913-89426a8abbd7', u'ip_address': u'10.0.0.10'}], u'network_type': u'vxlan', u'security_groups': []}, {u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'96609bfa-0e22-4bb7-8dba-6ef532ea6076', u'segmentation_id': None, u'device_owner': u'network:router_gateway', u'physical_network': u'provider', u'mac_address': u'fa:16:3e:77:78:86', u'device': u'tap60dbdc2f-a0', u'port_security_enabled': False, u'port_id': u'60dbdc2f-a01b-446d-bb5b-26ffac19a045', u'fixed_ips': [{u'subnet_id': u'afa7d205-3026-439f-aca7-295a9f9b2a71', u'ip_address': u'10.62.227.151'}], u'network_type': u'flat', u'security_groups': []}, {u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'971ffda2-e567-40a0-a2c8-b31a577fd4d3', u'segmentation_id': 10, u'device_owner': u'network:router_interface', u'physical_network': None, u'mac_address': u'fa:16:3e:81:1b:37', u'device': u'tapb1eaae00-e5', u'port_security_enabled': False, u'port_id': u'b1eaae00-e504-41f8-93a4-643687155bea', u'fixed_ips': [{u'subnet_id': u'3d596991-de8f-4ae4-8913-89426a8abbd7', u'ip_address': u'10.0.0.1'}], u'network_type': u'vxlan', u'security_groups': []}, {u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'96609bfa-0e22-4bb7-8dba-6ef532ea6076', u'segmentation_id': None, u'device_owner': u'network:dhcp', u'physical_network': u'provider', u'mac_address': u'fa:16:3e:5f:94:7d', u'device': u'tap795e6e86-94', u'port_security_enabled': False, u'port_id': u'795e6e86-94af-4b72-ae1a-5a324a017774', u'fixed_ips': [{u'subnet_id': u'afa7d205-3026-439f-aca7-295a9f9b2a71', u'ip_address': u'10.62.227.150'}], u'network_type': u'flat', u'security_groups': []}, {u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'85925305-b477-4cc6-9654-67d9bf1e7cd8', u'segmentation_id': 25, u'device_owner': u'network:dhcp', u'physical_network': None, u'mac_address': u'fa:16:3e:25:27:99', u'device': u'tap798c87d1-a2', u'port_security_enabled': False, u'port_id': u'798c87d1-a2d8-4df7-b7fc-5ab30918a0de', u'fixed_ips': [{u'subnet_id': u'4575c7f1-7f08-4917-9904-ec65af38619b', u'ip_address': u'20.0.0.100'}], u'network_type': u'vxlan', u'security_groups': []}, {u'profile': {}, u'network_qos_policy_id': None, u'qos_policy_id': None, u'allowed_address_pairs': [], u'admin_state_up': True, u'network_id': u'85925305-b477-4cc6-9654-67d9bf1e7cd8', u'segmentation_id': 25, u'device_owner': u'network:router_interface', u'physical_network': None, u'mac_address': u'fa:16:3e:9f:18:a9', u'device': u'tap0bb8efeb-10', u'port_security_enabled': False, u'port_id': u'0bb8efeb-108f-409a-82e7-c4c20f0d4f69', u'fixed_ips': [{u'subnet_id': u'4575c7f1-7f08-4917-9904-ec65af38619b', u'ip_address': u'20.0.0.1'}], u'network_type': u'vxlan', u'security_groups': []}](4) 對(duì)需要處理的設(shè)備,調(diào)用?self.process_network_devices(device_info) 函數(shù)進(jìn)行處理
(5). 調(diào)用 plug_interface
interface_plugged = self.mgr.plug_interface(network_id, segment,device, device_details['device_owner'])(6). 需要的話,使用已經(jīng)配置的或者新建 linux brige,并將 physical interface 設(shè)備加入其中
bridge_name = self.get_existing_bridge_name(physical_network) #獲取為 physical network 配置的 linux bridge bridge_name = self.get_bridge_name(network_id) #或者根據(jù) network id 生成 bridge name(7).根據(jù)不同的網(wǎng)絡(luò)類型,分別處理 vxlan bridge,flat bridge 和 vlan bridge
def ensure_physical_in_bridge(self, network_id,network_type,physical_network,segmentation_id):if network_type == p_const.TYPE_VXLAN:if self.vxlan_mode == lconst.VXLAN_NONE:LOG.error(_LE("Unable to add vxlan interface for network %s"),network_id)returnreturn self.ensure_vxlan_bridge(network_id, segmentation_id)# NOTE(nick-ma-z): Obtain mappings of physical bridge and interfacesphysical_bridge = self.get_existing_bridge_name(physical_network)physical_interface = self.interface_mappings.get(physical_network)if not physical_bridge and not physical_interface:LOG.error(_LE("No bridge or interface mappings"" for physical network %s"),physical_network)returnif network_type == p_const.TYPE_FLAT:return self.ensure_flat_bridge(network_id, physical_bridge,physical_interface)elif network_type == p_const.TYPE_VLAN:return self.ensure_vlan_bridge(network_id, physical_bridge,physical_interface,segmentation_id)對(duì)于 flat 類型的網(wǎng)絡(luò),調(diào)用 ensure_physical_in_bridge
def ensure_physical_in_bridge(self, network_id,network_type,physical_network,segmentation_id) if network_type == p_const.TYPE_FLAT: return self.ensure_flat_bridge(network_id, physical_bridge,physical_interface)如果有配置 physical bridge 的話,使用它;否則創(chuàng)建 bridge,并將物理網(wǎng)卡配置的 ip 地址和 gateway 從網(wǎng)卡挪到 linux bridge
def ensure_flat_bridge(self, network_id, phy_bridge_name,physical_interface): """Create a non-vlan bridge unless it already exists.""" if phy_bridge_name: return self.ensure_bridge(phy_bridge_name) #獲取預(yù)先配置好的 linux bridge else:bridge_name = self.get_bridge_name(network_id)ips, gateway = self.get_interface_details(physical_interface) if self.ensure_bridge(bridge_name, physical_interface, ips,gateway): #創(chuàng)建 bridge return physical_interface對(duì)于 vxlan 類型的 network,需要?jiǎng)?chuàng)建 vxlan interface
def ensure_vxlan_bridge(self, network_id, segmentation_id):"""Create a vxlan and bridge unless they already exist."""interface = self.ensure_vxlan(segmentation_id)if not interface:LOG.error(_LE("Failed creating vxlan interface for ""%(segmentation_id)s"),{segmentation_id: segmentation_id})returnbridge_name = self.get_bridge_name(network_id)self.ensure_bridge(bridge_name, interface)return interface創(chuàng)建 vxlan interface:
def ensure_vxlan(self, segmentation_id):"""Create a vxlan unless it already exists."""interface = self.get_vxlan_device_name(segmentation_id)if not ip_lib.device_exists(interface):LOG.debug("Creating vxlan interface %(interface)s for ""VNI %(segmentation_id)s",{'interface': interface,'segmentation_id': segmentation_id})args = {'dev': self.local_int}if self.vxlan_mode == lconst.VXLAN_MCAST:args['group'] = self.get_vxlan_group(segmentation_id)if cfg.CONF.VXLAN.ttl:args['ttl'] = cfg.CONF.VXLAN.ttlif cfg.CONF.VXLAN.tos:args['tos'] = cfg.CONF.VXLAN.tosif cfg.CONF.VXLAN.l2_population:args['proxy'] = cfg.CONF.VXLAN.arp_respondertry:int_vxlan = self.ip.add_vxlan(interface, segmentation_id,**args)(8). 將 tap 設(shè)備加入到 linux bridge 中
bridge_lib.BridgeDevice(bridge_name).addif(tap_device_name)
(9).?如果將一個(gè) tap 設(shè)備被刪除,那么 linux-bridge-agent 會(huì)發(fā)現(xiàn):
2016-10-26 10:29:58.347 30219 INFO neutron.agent.securitygroups_rpc [req-e3264065-6414-4b5a-8d2b-dfafad6fdde8 - - - - -] Remove device filter for set(['tap60dbdc2f-a0'])
2016-10-26 10:29:58.433 30219 INFO neutron.plugins.ml2.drivers.agent._common_agent [req-e3264065-6414-4b5a-8d2b-dfafad6fdde8 - - - - -] Attachment tap60dbdc2f-a0 removed
2016-10-26 10:29:58.536 30219 INFO neutron.plugins.ml2.drivers.agent._common_agent [req-e3264065-6414-4b5a-8d2b-dfafad6fdde8 - - - - -] Port tap60dbdc2f-a0 updated.
3. 關(guān)于上述工作過(guò)程的簡(jiǎn)單結(jié)論
3.1 簡(jiǎn)單結(jié)論
?
具有多個(gè) VLAN 租戶網(wǎng)絡(luò)時(shí)候的網(wǎng)絡(luò)元素示意圖:
?
?
?3.2 關(guān)于 unnumber interface
OpenStack 官方的 host networking 配置中,連接外網(wǎng)的 interface 可以是 unnumbered 的,從字面意思理解,就是該 interface 上不需要配置 IP 地址。
配置的時(shí)候,修改?/etc/network/interfaces:
# The provider network interface auto ens224 iface ens224 inet manual up ip link set dev $IFACE up down ip link set dev $IFACE down配置好以后:
root@controller:/home/sammy# ifconfig ens224 ens224 Link encap:Ethernet HWaddr 00:50:56:9c:4d:94UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1RX packets:27300737 errors:0 dropped:0 overruns:0 frame:0TX packets:61547 errors:0 dropped:0 overruns:0 carrier:0collisions:0 txqueuelen:1000RX bytes:31951077598 (31.9 GB) TX bytes:5966060 (5.9 MB)root@controller:/home/sammy# ifconfig brq96609bfa-0e brq96609bfa-0e Link encap:Ethernet HWaddr 00:50:56:9c:4d:94UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1RX packets:32855 errors:0 dropped:0 overruns:0 frame:0TX packets:2 errors:0 dropped:0 overruns:0 carrier:0collisions:0 txqueuelen:1000RX bytes:2731030 (2.7 MB) TX bytes:84 (84.0 B)具體原理不詳,但是應(yīng)該是因?yàn)?qrouter 的 qg network interface 和物理網(wǎng)絡(luò)中的路由器的網(wǎng)卡之間是網(wǎng)絡(luò)二層,因此中間的設(shè)備都是屬于二層的,因此不需要處于網(wǎng)絡(luò)三層的 IP 地址。
4. 使用 linux bridge 時(shí)的拓?fù)浣Y(jié)構(gòu)
4.1 網(wǎng)絡(luò)節(jié)點(diǎn)上
為了更清楚,我們來(lái)對(duì)比著看 linux bridge 和 ovs 的兩種方案:
linux 方案:
?
網(wǎng)絡(luò)服務(wù):
- Linux bridge agent
- L3 agent
- DHCP agent
- Metadata agent
Linux bridge agent 會(huì)為每個(gè) VLAN 虛擬網(wǎng)絡(luò)創(chuàng)建一個(gè) VLAN Bridge,它連接多個(gè)網(wǎng)元:
- VLAN 子接口,從物理網(wǎng)卡(圖中的 interface3)上創(chuàng)建,每個(gè)子接口對(duì)應(yīng)一個(gè)VLAN ID,其名稱格式為?device.sid,其中 device 是物理網(wǎng)卡名字比如 eth0,sid 是 vlan id。
- 連接虛擬機(jī)的 tap 接口
- 和 qrouter 連接的 tap 接口
- 和該網(wǎng)絡(luò)的 qdhcp 連接的 tap 接口
如果同時(shí)有 VXLAN 虛擬網(wǎng)絡(luò)的話(linux-bridge 不支持GRE 隧道模式),會(huì)為每個(gè) VLAN 虛擬網(wǎng)絡(luò)創(chuàng)建一個(gè) Tunnel bridge。它連接多個(gè)網(wǎng)元:
- vxlan interface,這種接口每個(gè)虛擬網(wǎng)絡(luò)一個(gè),名字格式為?vxlan-sid,其中 sid 是分段ID。
- 連接虛擬機(jī)的 tap 接口
- 和 qrouter 連接的 tap 接口
- 和該網(wǎng)絡(luò)的 qdhcp 連接的 tap 接口
安全組規(guī)則在 tunnel bridge 和 vlan bridge 上。
OVS 方案:
這里面,br-int 會(huì)負(fù)責(zé)加本地 VLAN 標(biāo)簽,br-tun 會(huì)負(fù)責(zé)將 VLAN ID 轉(zhuǎn)換為 VXLAN ID。
?
4.2 計(jì)算節(jié)點(diǎn)上
同樣來(lái)對(duì)比著看。
linux bridge:
網(wǎng)絡(luò)服務(wù):
- Linux bridge agent
和網(wǎng)絡(luò)節(jié)點(diǎn)類似,只不過(guò)沒(méi)有 qrouter 和 qdhcp,不在贅述。
OVS:
?
OVS 放在在 br-int 上實(shí)現(xiàn) VLAN 標(biāo)簽,在 br-tun 上實(shí)現(xiàn)隧道,在 qbr linux bridge 上實(shí)現(xiàn)安全組。
?
4.3 網(wǎng)絡(luò)路徑 - 南北向網(wǎng)絡(luò)流向
VLAN 網(wǎng)絡(luò)和VXLAN 網(wǎng)絡(luò)井水不犯河水。這圖上的配置中,計(jì)算節(jié)點(diǎn)和網(wǎng)絡(luò)節(jié)點(diǎn)上的物理網(wǎng)卡都分開(kāi)了。
4.4 網(wǎng)絡(luò)路徑 - 東西向(不同網(wǎng)絡(luò))
4.5 網(wǎng)絡(luò)路徑 - 東西向(同一個(gè)網(wǎng)絡(luò))
?
請(qǐng)?jiān)敿?xì)說(shuō)明和配置,請(qǐng)參閱參考文檔。
5. 一點(diǎn)結(jié)論
和基于 OVS 的二層網(wǎng)絡(luò)相比,
- 功能和架構(gòu)上:基于 linux bridge 的實(shí)現(xiàn)還是有一些短處,比如每個(gè)虛擬網(wǎng)絡(luò)就需要一個(gè)網(wǎng)橋,這在大規(guī)模環(huán)境中會(huì)帶領(lǐng)資源使用和管理上的問(wèn)題。其好處是本身架構(gòu)比較清晰。
- 性能上:基本上差不多,如下圖所示,不管是 vxlan 還是 vlan。
?參考資料:
- https://docs.openstack.org/kilo/networking-guide/scenario_legacy_lb.html
- https://www.slideshare.net/JamesDenton1/2014-openstack-summit-neutron-ovs-to-linuxbridge-migration
- https://robhirschfeld.com/2013/10/16/openstack-neutron-using-linux-bridges-technical-explanation/
歡迎大家關(guān)注我的個(gè)人公眾號(hào):
?
轉(zhuǎn)載于:https://www.cnblogs.com/sammyliu/p/5999612.html
總結(jié)
以上是生活随笔為你收集整理的理解 neutron(15):Neutron Linux Bridge + VLAN/VXLAN 虚拟网络的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: EconomicIndoor集成测试
- 下一篇: 在linux上一行代码不用写实现自动采集