码迷,mamicode.com
首页 > 其他好文 > 详细

网络虚拟化

时间:2019-01-09 22:48:08      阅读:254      评论:0      收藏:0      [点我收藏+]

标签:drop   arc   研发   汇聚   sha   vxlan   基于   algo   语言   

网络虚拟化技术
OpenVSwitch:虚拟交换机
VLAN, VXLAN
虚拟路由器

什么是VLAN?
Virtual LAN:LAN即为广播帧到的节点范围,也即能够直接通信的范围;

VLAN:
基于MAC地址
基于交换机Port实现
基于IP地址实现
基于用户实现

交换机接口的类型:
访问链接:access link
汇聚链接:trunk link

VLAN的汇聚方式:
IEEE 802.1q
ISL:Inter Switch Link

VLAN间路由:
路由器:
访问链接:router为每个VLAN提供一个接口
汇聚链接:router只向交换机提供一个接口
三层交换机:

网络虚拟化:
复杂的虚拟化网络:
netns
OpenVswitch

    OVS:基于C语言研发,
    802.1q, trunk, access
    NIC bonding
            NetFlow, sFlow
            Qos配置及策略
            GRE, VxLAN, 
            OpenFlow

    OVS的组成部分:
        ovs-vswitchd:OVS daemon,实现数据报文交换功能,和Linux内核兼容模块一同实现基于流的交换技术;
            ovsdb-server:轻量级的数据库服务,主要保存了整个OVS的配置信息,例如接口、交换内容、VLAN等等,ovs-vswithed的交换功能基于此库实现;
            ovs-dpctl:配置交换机内核模块的工具程序,用于控制转发规则;
            ovs-vsctl:用于获取或更改ovs-vswitchd的配置信息,其修改操作会保存至ovsdb-server中;
            ovs-appctl
            ovsdbmonitor:gui工具显示ovsdb-server中的数据信息的;
            ovs-controller:流控工具
            ovs-ofctl
            ovs-pki:为openflow创建管理pki的命令行工具;

实验环境:
操作系统:Centos6.6
IP地址:172.16.100.6
内核:2.6.32-504.el6.x86_64

[root@kvm ~]# modinfo 8021q
filename:       /lib/modules/3.10.0-862.el7.x86_64/kernel/net/8021q/8021q.ko.xz
version:        1.8
license:        GPL
alias:          rtnl-link-vlan
retpoline:      Y
rhelversion:    7.5
srcversion:     A57F0AC30965A554203D4E3
depends:        mrp,garp
intree:         Y
vermagic:       3.10.0-862.el7.x86_64 SMP mod_unload modversions
signer:         CentOS Linux kernel signing key
sig_key:        3A:F3:CE:8A:74:69:6E:F1:BD:0F:37:E5:52:62:7B:71:09:E3:2B:96
sig_hashalgo:   sha256
[root@kvm ~]# modprobe 8021q
[root@kvm ~]# yum info vconfig
Name        : vconfig
Arch        : x86_64
Version     : 1.9
Release     : 8.1.el6
Size        : 178 k
Repo        : installed
From repo   : anaconda-CentOS-201410241409.x86_64
Summary     : Linux 802.1q VLAN configuration utility
URL         : http://www.candelatech.com/~greear/vlan.html
License     : GPLv2+
Description : The vconfig program configures and adjusts 802.1q VLAN parameters.
[root@kvm ~]# ls /proc/net/vlan/
config

实验环境:
node1:
操作系统:Centos6.6
IP地址:172.16.100.6
内核:2.6.32-504.el6.x86_64
网卡1:VMnet0
网卡2:VMnet1
网卡3:VMnet8
node2:
操作系统:Centos6.6
IP地址:172.16.100.6
内核:2.6.32-504.el6.x86_64
网卡1:VMnet0 172.16.100.20
网卡2:VMnet1
网卡3:VMnet2
node3:
操作系统:Centos6.6
IP地址:172.16.100.6
内核:2.6.32-504.el6.x86_64
网卡1:VMnet0 172.16.100.30
网卡2:VMnet1
网卡3:VMnet2

node2:

[root@node2 network-scripts]# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0C:29:90:D0:92
          inet addr:172.16.100.20  Bcast:172.16.100.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe90:d092/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1402 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1191 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:119155 (116.3 KiB)  TX bytes:118239 (115.4 KiB)

eth1      Link encap:Ethernet  HWaddr 00:0C:29:90:D0:A6
          inet addr:192.168.10.7  Bcast:192.168.10.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe90:d0a6/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:20 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:1244 (1.2 KiB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

node3:

[root@node3 network-scripts]# ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0C:29:D6:6A:92
          inet addr:172.16.100.30  Bcast:172.16.100.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fed6:6a92/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:681 errors:0 dropped:0 overruns:0 frame:0
          TX packets:602 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:60082 (58.6 KiB)  TX bytes:62754 (61.2 KiB)

eth1      Link encap:Ethernet  HWaddr 00:0C:29:D6:6A:A6
          inet addr:192.168.10.8  Bcast:192.168.10.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fed6:6aa6/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 b)  TX bytes:364 (364.0 b)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

node1:

网络虚拟化

标签:drop   arc   研发   汇聚   sha   vxlan   基于   algo   语言   

原文地址:http://blog.51cto.com/smoke520/2340864

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!