vxlan 通过 l3gateway 访问外网

节点2上ping 8.8.8.8

[root@evpn2 ~]# ip netns exec host2 ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=5 ttl=42 time=880 ms
64 bytes from 8.8.8.8: icmp_seq=6 ttl=42 time=14.3 ms
64 bytes from 8.8.8.8: icmp_seq=7 ttl=42 time=14.2 ms
64 bytes from 8.8.8.8: icmp_seq=8 ttl=42 time=14.3 ms
64 bytes from 8.8.8.8: icmp_seq=9 ttl=42 time=14.2 ms
^C
--- 8.8.8.8 ping statistics ---
9 packets transmitted, 5 received, 44.4444% packet loss, time 168ms
rtt min/avg/max/mdev = 14.174/187.402/880.061/346.329 ms
[root@evpn2 ~]# tcpdump -i    default_g1   -nnvv  host 8.8.8.8
tcpdump: listening on default_g1, link-type EN10MB (Ethernet), capture size 262144 bytes
11:50:20.897949 IP (tos 0x0, ttl 63, id 36340, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 1, length 64
11:50:21.933864 IP (tos 0x0, ttl 63, id 36420, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 2, length 64
11:50:22.973862 IP (tos 0x0, ttl 63, id 36426, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 3, length 64
11:50:24.013861 IP (tos 0x0, ttl 63, id 36529, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 4, length 64
11:50:25.053884 IP (tos 0x0, ttl 63, id 36631, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 5, length 64
11:50:25.933832 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 10392, seq 5, length 64
11:50:26.054159 IP (tos 0x0, ttl 63, id 36702, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 6, length 64
11:50:26.068335 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 10392, seq 6, length 64
11:50:27.055494 IP (tos 0x0, ttl 63, id 36716, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 7, length 64
11:50:27.069559 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 10392, seq 7, length 64
11:50:28.056763 IP (tos 0x0, ttl 63, id 36763, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 8, length 64
11:50:28.070986 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 10392, seq 8, length 64
11:50:29.058153 IP (tos 0x0, ttl 63, id 36859, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 10392, seq 9, length 64
11:50:29.072258 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 10392, seq 9, length 64


[root@evpn2 ~]# tcpdump -i    enp1s0   -nnvv  host 8.8.8.8
tcpdump: listening on enp1s0, link-type EN10MB (Ethernet), capture size 262144 bytes
11:50:20.897974 IP (tos 0x0, ttl 62, id 36340, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 1, length 64
11:50:21.933891 IP (tos 0x0, ttl 62, id 36420, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 2, length 64
11:50:21.948228 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 2, length 64
11:50:22.973890 IP (tos 0x0, ttl 62, id 36426, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 3, length 64
11:50:24.013891 IP (tos 0x0, ttl 62, id 36529, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 4, length 64
11:50:24.027866 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 4, length 64
11:50:25.053830 IP (tos 0xd4, ttl 64, id 4965, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 2, length 64
11:50:25.053866 IP (tos 0xd4, ttl 64, id 4966, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 4, length 64
11:50:25.053916 IP (tos 0x0, ttl 62, id 36631, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 5, length 64
11:50:25.067903 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 5, length 64
11:50:26.054185 IP (tos 0x0, ttl 62, id 36702, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 6, length 64
11:50:26.068305 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 6, length 64
11:50:27.055522 IP (tos 0x0, ttl 62, id 36716, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 7, length 64
11:50:27.069519 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 7, length 64
11:50:28.056792 IP (tos 0x0, ttl 62, id 36763, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 8, length 64
11:50:28.070955 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 8, length 64
11:50:29.058181 IP (tos 0x0, ttl 62, id 36859, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 9, length 64
11:50:29.072228 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 9, length 64
^C
18 packets captured
18 packets received by filter
0 packets dropped by kernel
evpn2.novalocal# ip route  show vrf evpn-vrf
% Unknown command: ip route  show vrf evpn-vrf
evpn2.novalocal# show ip route   vrf evpn-vrf
Codes: K - kernel route, C - connected, S - static, R - RIP,
       O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
       T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
       F - PBR, f - OpenFabric,
       > - selected route, * - FIB route, q - queued route, r - rejected route


VRF evpn-vrf:
K>* 0.0.0.0/0 [0/0] via 5.5.5.254, default_g1, 2d13h14m
C>* 2.2.2.0/24 is directly connected, br30, 4d21h40m
B>* 3.3.3.2/32 [20/0] via 10.10.18.209, br100 onlink, 00:04:30
C>* 5.5.5.0/24 is directly connected, default_g1, 2d13h14m
C>* 9.9.9.0/24 is directly connected, br20, 4d20h29m
B>* 10.10.16.0/24 [20/0] via 10.10.18.209, br100 onlink, 17:32:08
evpn2.novalocal# exit
[root@evpn2 ~]# ip route show vrf vepn-vrf
Error: argument "vepn-vrf" is wrong: Invalid VRF

[root@evpn2 ~]# ip route show vrf evpn-vrf
default via 5.5.5.254 dev default_g1 
2.2.2.0/24 dev br30 proto kernel scope link src 2.2.2.254 
5.5.5.0/24 dev default_g1 proto kernel scope link src 5.5.5.253 
9.9.9.0/24 dev br20 proto kernel scope link src 9.9.9.254 
10.10.16.0/24 via 10.10.18.209 dev br100 proto bgp metric 20 onlink 

ping 10.10.16.81 无法通,因为10.10.18.209节点上发布了net,但是没有配网关

[root@evpn2 ~]# ip netns exec host3 ping 10.10.16.81
PING 10.10.16.81 (10.10.16.81) 56(84) bytes of data.
^C
--- 10.10.16.81 ping statistics ---
10 packets transmitted, 0 received, 100% packet loss, time 405ms

节点1上ping 8.8.8.8

[root@evpn1 ~]# ip netns exec host2 ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=7 ttl=41 time=14.4 ms
64 bytes from 8.8.8.8: icmp_seq=8 ttl=41 time=14.4 ms
64 bytes from 8.8.8.8: icmp_seq=10 ttl=41 time=14.5 ms
64 bytes from 8.8.8.8: icmp_seq=13 ttl=41 time=14.4 ms
64 bytes from 8.8.8.8: icmp_seq=14 ttl=41 time=14.5 ms
64 bytes from 8.8.8.8: icmp_seq=15 ttl=41 time=14.3 ms
^C
--- 8.8.8.8 ping statistics ---
21 packets transmitted, 6 received, 71.4286% packet loss, time 666ms
rtt min/avg/max/mdev = 14.315/14.419/14.538/0.081 ms
[root@evpn2 ~]# tcpdump -i    default_g1   -nnvv  host 8.8.8.8
tcpdump: listening on default_g1, link-type EN10MB (Ethernet), capture size 262144 bytes
11:55:28.155272 IP (tos 0x0, ttl 62, id 46583, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 2, length 64
11:55:29.195230 IP (tos 0x0, ttl 62, id 46604, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 3, length 64
11:55:30.235236 IP (tos 0x0, ttl 62, id 46688, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 4, length 64
11:55:31.275255 IP (tos 0x0, ttl 62, id 46765, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 5, length 64
11:55:32.315225 IP (tos 0x0, ttl 62, id 46845, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 6, length 64
11:55:33.355216 IP (tos 0x0, ttl 62, id 46946, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 7, length 64
11:55:33.369203 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 7, length 64
11:55:34.356724 IP (tos 0x0, ttl 62, id 46963, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 8, length 64
11:55:34.370723 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 8, length 64
11:55:35.358187 IP (tos 0x0, ttl 62, id 47021, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 9, length 64
11:55:36.395223 IP (tos 0x0, ttl 62, id 47030, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 10, length 64
11:55:36.409396 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 10, length 64
11:55:37.396807 IP (tos 0x0, ttl 62, id 47119, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 11, length 64
11:55:38.475226 IP (tos 0x0, ttl 62, id 47166, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 12, length 64
11:55:39.515239 IP (tos 0x0, ttl 62, id 47180, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 13, length 64
11:55:39.529240 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 13, length 64
11:55:40.516712 IP (tos 0x0, ttl 62, id 47223, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 14, length 64
11:55:40.530875 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 14, length 64
11:55:41.518274 IP (tos 0x0, ttl 62, id 47246, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 15, length 64
11:55:41.532271 IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 5.5.5.253: ICMP echo reply, id 19102, seq 15, length 64
11:55:42.519678 IP (tos 0x0, ttl 62, id 47285, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 16, length 64
11:55:43.595227 IP (tos 0x0, ttl 62, id 47325, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 17, length 64
11:55:44.635246 IP (tos 0x0, ttl 62, id 47353, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 18, length 64
11:55:45.675229 IP (tos 0x0, ttl 62, id 47391, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 19, length 64
11:55:46.715242 IP (tos 0x0, ttl 62, id 47459, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 20, length 64
11:55:47.755271 IP (tos 0x0, ttl 62, id 47489, offset 0, flags [DF], proto ICMP (1), length 84)
    5.5.5.253 > 8.8.8.8: ICMP echo request, id 19102, seq 21, length 64
^C
26 packets captured
26 packets received by filter
0 packets dropped by kernel
[root@evpn2 ~]# tcpdump -i    enp1s0   -nnvv  host 8.8.8.8
tcpdump: listening on enp1s0, link-type EN10MB (Ethernet), capture size 262144 bytes
11:55:28.155300 IP (tos 0x0, ttl 61, id 46583, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 2, length 64
11:55:28.169439 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 2, length 64
11:55:29.195251 IP (tos 0x0, ttl 61, id 46604, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 3, length 64
11:55:29.209475 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 3, length 64
11:55:30.235257 IP (tos 0x0, ttl 61, id 46688, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 4, length 64
11:55:30.249534 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 4, length 64
11:55:31.275277 IP (tos 0x0, ttl 61, id 46765, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 5, length 64
11:55:31.289335 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 5, length 64
11:55:31.293815 IP (tos 0xd4, ttl 64, id 34480, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 2, length 64
11:55:31.293850 IP (tos 0xd4, ttl 64, id 34481, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 3, length 64
11:55:31.293856 IP (tos 0xd4, ttl 64, id 34482, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 4, length 64
11:55:31.293861 IP (tos 0xd4, ttl 64, id 34483, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 5, length 64
11:55:32.315247 IP (tos 0x0, ttl 61, id 46845, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 6, length 64
11:55:33.355238 IP (tos 0x0, ttl 61, id 46946, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 7, length 64
11:55:33.369183 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 7, length 64
11:55:34.356753 IP (tos 0x0, ttl 61, id 46963, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 8, length 64
11:55:34.370705 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 8, length 64
11:55:35.358216 IP (tos 0x0, ttl 61, id 47021, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 9, length 64
11:55:36.395253 IP (tos 0x0, ttl 61, id 47030, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 10, length 64
11:55:36.409381 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 10, length 64
11:55:37.396837 IP (tos 0x0, ttl 61, id 47119, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 11, length 64
11:55:38.475252 IP (tos 0x0, ttl 61, id 47166, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 12, length 64
11:55:39.515259 IP (tos 0x0, ttl 61, id 47180, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 13, length 64
11:55:39.529224 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 13, length 64
11:55:40.516743 IP (tos 0x0, ttl 61, id 47223, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 14, length 64
11:55:40.530855 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 14, length 64
11:55:41.518298 IP (tos 0x0, ttl 61, id 47246, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 15, length 64
11:55:41.532246 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 15, length 64
11:55:42.519707 IP (tos 0x0, ttl 61, id 47285, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 16, length 64
11:55:43.595247 IP (tos 0x0, ttl 61, id 47325, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 17, length 64
11:55:43.609333 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 17, length 64
11:55:44.635267 IP (tos 0x0, ttl 61, id 47353, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 18, length 64
11:55:44.649322 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 18, length 64
11:55:45.675250 IP (tos 0x0, ttl 61, id 47391, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 19, length 64
11:55:45.689124 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 19, length 64
11:55:46.715263 IP (tos 0x0, ttl 61, id 47459, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 20, length 64
11:55:46.729232 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 20, length 64
11:55:46.733813 IP (tos 0xd4, ttl 64, id 35091, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 17, length 64
11:55:46.733845 IP (tos 0xd4, ttl 64, id 35092, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 18, length 64
11:55:46.733851 IP (tos 0xd4, ttl 64, id 35093, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 19, length 64
11:55:46.733856 IP (tos 0xd4, ttl 64, id 35094, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 20, length 64
11:55:47.755291 IP (tos 0x0, ttl 61, id 47489, offset 0, flags [DF], proto ICMP (1), length 84)
    10.10.18.212 > 8.8.8.8: ICMP echo request, id 2, seq 21, length 64
11:55:47.769292 IP (tos 0x74, ttl 44, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 21, length 64
11:55:50.893835 IP (tos 0xd4, ttl 64, id 35290, offset 0, flags [none], proto ICMP (1), length 112)
    10.10.18.212 > 8.8.8.8: ICMP host 10.10.18.212 unreachable, length 92
        IP (tos 0x74, ttl 43, id 0, offset 0, flags [none], proto ICMP (1), length 84)
    8.8.8.8 > 10.10.18.212: ICMP echo reply, id 2, seq 21, length 64
^C
44 packets captured
44 packets received by filter
0 packets dropped by kernel
[root@evpn1 ~]# ip route show vrf evpn-vrf
default via 10.10.18.212 dev br100 proto bgp metric 20 onlink 
2.2.2.0/24 dev br10 proto kernel scope link src 2.2.2.254 
3.3.3.0/24 dev br20 proto kernel scope link src 3.3.3.254 
9.9.9.0/24 via 10.10.18.212 dev br100 proto bgp metric 20 onlink 
[root@evpn1 ~]# vtysh

Hello, this is FRRouting (version 7.3-MyOwnFRRVersion).
Copyright 1996-2005 Kunihiro Ishiguro, et al.

evpn1# ip route  show vrf evpn-vrf
% Unknown command: ip route  show vrf evpn-vrf
evpn1#  show ip route   vrf evpn-vrf
Codes: K - kernel route, C - connected, S - static, R - RIP,
       O - OSPF, I - IS-IS, B - BGP, E - EIGRP, N - NHRP,
       T - Table, v - VNC, V - VNC-Direct, A - Babel, D - SHARP,
       F - PBR, f - OpenFabric,
       > - selected route, * - FIB route, q - queued route, r - rejected route


VRF evpn-vrf:
B>* 0.0.0.0/0 [20/0] via 10.10.18.212, br100 onlink, 17:28:56
C>* 2.2.2.0/24 is directly connected, br10, 4d21h56m
C>* 3.3.3.0/24 is directly connected, br20, 3d21h20m
B>* 9.9.9.0/24 [20/0] via 10.10.18.212, br100 onlink, 3d01h49m

猜你喜欢

转载自www.cnblogs.com/dream397/p/12551338.html