前往小程序,Get更优阅读体验!
立即前往
首页
学习
活动
专区
工具
TVP
发布
社区首页 >专栏 >Simple L2TPv3 Dynami

Simple L2TPv3 Dynami

作者头像
py3study
发布2020-01-14 12:09:02
3210
发布2020-01-14 12:09:02
举报
文章被收录于专栏:python3

Simple L2TPv3 Dynamic Tunnels

topo:

------------------------------------------------------------------------------

      fa1/0          fa2/0          fa1/0        fa0/0 AS1-CE3 ------ AS1-PE3  ------- AS1-C ----- AS1-PE1 -----AS1-CE1             fa1/0             fa2/0        fa1/0        fa0/0  

------------------------------------------------------------------------------

AS1-CE3 configuration:

hostname AS1-CE3 ! ip subnet-zero ! ! interface Loopback1  ip address 192.168.11.1 255.255.255.0 ! interface FastEthernet0/0  no ip address  shutdown  duplex auto  speed auto ! interface FastEthernet1/0  description connect to AS1-PE3 fa1/0 via L2TP to AS1-CE1  ip address 192.168.1.1 255.255.255.0  duplex auto  speed auto ! ip classless no ip http server ! ! line con 0  exec-timeout 0 0  logging synchronous line aux 0 line vty 0 4 ! end ------------------------------------------------------------------------------

AS1-PE3 configuration:

hostname AS1-PE3 ! boot-start-marker boot-end-marker ! ! ip subnet-zero ! ! ip cef no ip domain-lookup mpls label range 300 399 tag-switching tdp router-id Loopback0 pseudowire-class dynamic  encapsulation l2tpv3  ip local interface Loopback101 ! interface Loopback0  ip address 100.1.1.3 255.255.255.255  no ip directed-broadcast ! interface Loopback101  description lookback for L2TPv3 to Customer1  ip address 100.254.1.1 255.255.255.255  no ip directed-broadcast ! interface FastEthernet0/0  no ip address  no ip directed-broadcast  shutdown ! interface FastEthernet1/0  description connect to AS1-CE3 fa1/0 via L2TP to AS1-PE1 by James  no ip address  no ip directed-broadcast  tag-switching ip  no cdp enable  xconnect 100.254.1.2 2 pw-class dynamic ! interface FastEthernet2/0  description connect to AS1-C fa2/0  ip address 172.16.34.3 255.255.255.0  no ip directed-broadcast  tag-switching ip ! router ospf 1  log-adjacency-changes  network 100.1.1.3 0.0.0.0 area 0  network 100.254.1.1 0.0.0.0 area 0  network 172.16.0.0 0.0.255.255 area 0 end

------------------------------------------------------------------------------ AS1-C configuration:

hostname AS1-C ! boot-start-marker boot-end-marker ! ! ip subnet-zero ! ! ip cef no ip domain-lookup mpls label range 400 499 tag-switching tdp router-id Loopback0 ! ! !         interface Loopback0  ip address 100.1.1.4 255.255.255.255  no ip directed-broadcast ! interface FastEthernet0/0  no ip address  no ip directed-broadcast  shutdown ! interface FastEthernet1/0  description connect to AS1-PE1 fa1/0  ip address 172.16.14.4 255.255.255.0  no ip directed-broadcast  tag-switching ip ! interface FastEthernet2/0  description connect to AS1-PE3 fa2/0  ip address 172.16.34.4 255.255.255.0  no ip directed-broadcast  tag-switching ip ! interface FastEthernet3/0  no ip address  no ip directed-broadcast  shutdown ! router ospf 1  log-adjacency-changes  network 100.1.1.4 0.0.0.0 area 0  network 172.16.0.0 0.0.255.255 area 0 ! ip classless ! ! ! control-plane ! line con 0  exec-timeout 0 0  logging synchronous  stopbits 1 line aux 0  stopbits 1 line vty 0 4 !         no cns aaa enable end

------------------------------------------------------------------------------

AS1-PE1 configuration:

hostname AS1-PE1 ! boot-start-marker boot-end-marker ! ! ip subnet-zero ! ! ip cef no ip domain-lookup mpls label range 100 199 tag-switching tdp router-id Loopback0 pseudowire-class dynamic  encapsulation l2tpv3  ip local interface Loopback101 ! ! ! ! interface Loopback0  ip address 100.1.1.1 255.255.255.255  no ip directed-broadcast ! interface Loopback101  description lookback for L2TPv3 to Customer1  ip address 100.254.1.2 255.255.255.255  no ip directed-broadcast ! interface FastEthernet0/0  description connet to AS1-CE1 via L2TP to AS1-PE3 by James  no ip address  no ip directed-broadcast  no cdp enable  xconnect 100.254.1.1 2 pw-class dynamic ! interface FastEthernet1/0  description connect to AS1-C fa1/0  ip address 172.16.14.1 255.255.255.0  no ip directed-broadcast  tag-switching ip ! interface FastEthernet2/0  no ip address  no ip directed-broadcast  shutdown ! interface FastEthernet3/0  no ip address  no ip directed-broadcast  shutdown ! router ospf 1  log-adjacency-changes  network 100.1.1.1 0.0.0.0 area 0  network 100.254.1.2 0.0.0.0 area 0  network 172.16.0.0 0.0.255.255 area 0 ! ip classless ! ! !         control-plane ! ! line con 0  exec-timeout 0 0  logging synchronous  stopbits 1 line aux 0  stopbits 1 line vty 0 4 ! no cns aaa enable end

------------------------------------------------------------------------------ AS1-CE1 configuration:

hostname AS1-CE1 ! ! ip subnet-zero ! ! interface Loopback0  no ip address ! interface Loopback1  ip address 192.168.13.1 255.255.255.0 !         interface FastEthernet0/0  description connec to AS1-PE1 fa0/0 to connect AS1-CE3  ip address 192.168.1.3 255.255.255.0  duplex auto  speed auto ! interface FastEthernet1/0  no ip address  shutdown  duplex auto  speed auto ! ip classless ip http server ! ! line con 0  exec-timeout 0 0  logging synchronous line aux 0 line vty 0 4 ! end ------------------------------------------------------------------------------ AS1-CE1 ping AS1-CE3

AS1-CE1#ping 192.168.1.1    

Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 24/43/92 ms AS1-CE1#sh ip arp            Protocol  Address          Age (min)  Hardware Addr   Type   Interface Internet  192.168.1.1            19   cc07.0fc0.0010  ARPA   FastEthernet0/0 Internet  192.168.1.3             -   cc05.0fc0.0000  ARPA   FastEthernet0/0

AS1-CE3 ping AS1-CE1

AS1-CE3#ping 192.168.1.3

Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 192.168.1.3, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 16/39/52 ms

AS1-CE3#sh ip arp Protocol  Address          Age (min)  Hardware Addr   Type   Interface Internet  192.168.1.1             -   cc07.0fc0.0010  ARPA   FastEthernet1/0 Internet  192.168.1.3            20   cc05.0fc0.0000  ARPA   FastEthernet1/0

------------------------------------------------------------------------------

AS1-PE3#show l2tun tunnel all  Tunnel Information Total tunnels 1 sessions 1

Tunnel id 7666 is up, remote id is 40568, 1 active sessions   Tunnel state is established, time since change 00:23:38   Tunnel transport is IP (115)   Remote tunnel name is AS1-PE1     Internet Address 100.254.1.2, port 0   Local tunnel name is AS1-PE3     Internet Address 100.254.1.1, port 0   Tunnel domain is   VPDN group for tunnel is -   L2TP class for tunnel is l2tp_default_class   213 packets sent, 208 received   21636 bytes sent, 21336 received   Control Ns 25, Nr 27   Local RWS 3000 (default), Remote RWS 3000 (max)   Tunnel PMTU checking disabled   Retransmission time 1, max 1 seconds   Unsent queuesize 0, max 0   Resend queuesize 0, max 1   Total resends 0, ZLB ACKs sent 25   Total peer authentication failures 0   Current nosession queue check 0 of 5   Retransmit time distribution: 0 0 0 0 0 0 0 0 0   Sessions disconnected due to lack of resources 0   Control message authentication is disabled

AS1-PE3#show l2tun session all  Session Information Total tunnels 1 sessions 1

Session id 52461 is up, tunnel id 7666   Remote session id is 9649, remote tunnel id 40568 Session Layer 2 circuit, type is Ethernet, name is FastEthernet1/0   Session vcid is 2   Circuit state is UP     Local circuit state is UP     Remote circuit state is UP Call serial number is 274000000 Remote tunnel name is AS1-PE1   Internet address is 100.254.1.2 Local tunnel name is AS1-PE3   Internet address is 100.254.1.1 IP protocol 115   Session is L2TP signalled   Session state is established, time since change 00:23:52     214 Packets sent, 209 received     21696 Bytes sent, 21396 received     Receive packets dropped:       out-of-order:             0       total:                    0     Send packets dropped:       exceeded session MTU:     0       total:                    0   DF bit off, ToS reflect disabled, ToS value 0, TTL value 255   No session cookie information available   FS cached header information:     encap size = 24 bytes     00000000 00000000 00000000 00000000     00000000 00000000   Sequencing is off AS1-PE3#

AS1-PE3#show l2tun tunnel summary  Tunnel Information Total tunnels 1 sessions 1

LocID RemID Remote Name   State  Remote Address  Port  Sessions L2TPclass 7666  40568 AS1-PE1       est    100.254.1.2     0     1        l2tp_default_cl AS1-PE3#

AS1-PE3#show l2tun tunnel state  Tunnel Information Total tunnels 1 sessions 1

LocID RemID Local Name    Remote Name   State  Last-Chg 7666  40568 AS1-PE3       AS1-PE1       est    00:24:39

AS1-PE3#show l2tun tunnel transport  Tunnel Information Total tunnels 1 sessions 1

LocID Type Prot  Local Address   Port  Remote Address  Port 7666  IP   115   100.254.1.1     0     100.254.1.2     0    AS1-PE3#

AS1-PE3#show l2tun session brief  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    State     Username, Intf/                                                       sess/cir  Vcid, Circuit                   52461      7666       100.254.1.2     est,UP    2, Fa1/0                        AS1-PE3#show l2tun session circuit  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    Type Stat Username, Intf/                                                                 Vcid, Circuit                   52461      7666       100.254.1.2     ETH  UP   2, Fa1/0                        AS1-PE3#show l2tun session interworking  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    Type IWrk Username, Intf/                                                                 Vcid, Circuit                   52461      7666       100.254.1.2     ETH  -    2, Fa1/0                        AS1-PE3#show l2tun session l2           AS1-PE3#show l2tun session l2tp  Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Username, Intf/                          State                                  Vcid, Circuit                                  52461      9649       7666       2, Fa1/0                                 est  

AS1-PE3#show l2tun session sequence  Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Seq Ns         Nr         Out-of-order 52461      9649       7666       No  0          0          0           AS1-PE3#show l2tun session state  Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Username, Intf/                          State                                  Vcid, Circuit                                  52461      9649       7666       2, Fa1/0                                 est 

AS1-PE1#show l2tun tunnel all  Tunnel Information Total tunnels 1 sessions 1

Tunnel id 40568 is up, remote id is 7666, 1 active sessions   Tunnel state is established, time since change 00:25:12   Tunnel transport is IP (115)   Remote tunnel name is AS1-PE3     Internet Address 100.254.1.1, port 0   Local tunnel name is AS1-PE1     Internet Address 100.254.1.2, port 0   Tunnel domain is   VPDN group for tunnel is -   L2TP class for tunnel is l2tp_default_class   218 packets sent, 223 received   22196 bytes sent, 22496 received   Control Ns 29, Nr 27   Local RWS 3000 (default), Remote RWS 3000 (max)   Tunnel PMTU checking disabled   Retransmission time 1, max 1 seconds   Unsent queuesize 0, max 0   Resend queuesize 0, max 2   Total resends 1, ZLB ACKs sent 25   Total peer authentication failures 0   Current nosession queue check 0 of 5   Retransmit time distribution: 0 0 1 0 0 0 0 0 0   Sessions disconnected due to lack of resources 0   Control message authentication is disabled AS1-PE1#show l2tun session all  Session Information Total tunnels 1 sessions 1

Session id 9649 is up, tunnel id 40568   Remote session id is 52461, remote tunnel id 7666 Session Layer 2 circuit, type is Ethernet, name is FastEthernet0/0   Session vcid is 2   Circuit state is UP     Local circuit state is UP     Remote circuit state is UP Call serial number is 274000000 Remote tunnel name is AS1-PE3   Internet address is 100.254.1.1 Local tunnel name is AS1-PE1   Internet address is 100.254.1.2 IP protocol 115   Session is L2TP signalled   Session state is established, time since change 00:25:20     219 Packets sent, 224 received     22256 Bytes sent, 22556 received     Receive packets dropped:       out-of-order:             0       total:                    0     Send packets dropped:       exceeded session MTU:     0       total:                    0   DF bit off, ToS reflect disabled, ToS value 0, TTL value 255   No session cookie information available   FS cached header information:     encap size = 24 bytes     00000000 00000000 00000000 00000000     00000000 00000000   Sequencing is off

AS1-PE1#show l2tun tunnel summary  Tunnel Information Total tunnels 1 sessions 1

LocID RemID Remote Name   State  Remote Address  Port  Sessions L2TPclass 40568 7666  AS1-PE3       est    100.254.1.1     0     1        l2tp_default_cl AS1-PE1#show l2tun tunnel st      AS1-PE1#show l2tun tunnel state  Tunnel Information Total tunnels 1 sessions 1

LocID RemID Local Name    Remote Name   State  Last-Chg 40568 7666  AS1-PE1       AS1-PE3       est    00:25:45 AS1-PE1#show l2tun tunnel tr    AS1-PE1#show l2tun tunnel transport  Tunnel Information Total tunnels 1 sessions 1

LocID Type Prot  Local Address   Port  Remote Address  Port 40568 IP   115   100.254.1.2     0     100.254.1.1     0

AS1-PE1#show l2tun session brief  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    State     Username, Intf/                                                       sess/cir  Vcid, Circuit                   9649       40568      100.254.1.1     est,UP    2, Fa0/0                        AS1-PE1#show l2tun session circuit  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    Type Stat Username, Intf/                                                                 Vcid, Circuit                   9649       40568      100.254.1.1     ETH  UP   2, Fa0/0                        AS1-PE1#show l2tun session interworking  Session Information Total tunnels 1 sessions 1

LocID      TunID      Peer-address    Type IWrk Username, Intf/                                                                 Vcid, Circuit                   9649       40568      100.254.1.1     ETH  -    2, Fa0/0                        AS1-PE1#show l2tun session l2tp         Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Username, Intf/                          State                                  Vcid, Circuit                                  9649       52461      40568      2, Fa0/0                                 est   AS1-PE1#show l2tun session packets  Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Pkts-In    Pkts-Out   Bytes-In   Bytes-Out 9649       52461      40568      242        237        24416      24116     AS1-PE1#show l2tun session sequence  Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Seq Ns         Nr         Out-of-order 9649       52461      40568      No  0          0          0         AS1-PE1#show l2tun session state    Session Information Total tunnels 1 sessions 1

LocID      RemID      TunID      Username, Intf/                          State                                  Vcid, Circuit                                  9649       52461      40568      2, Fa0/0                                 est

本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2019/07/02 ,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档