Tuesday, March 29, 2011

L2TPV3实现端口到端口的二层VPN


1.尝试描述 有两个客户,一个VPNA,一个VPNB,经由过程运营收集成立端口到端口的二层VPN。VPNA的CE之间跑OSPF,VPNB的CE之间跑RIPV2。使得两个客户能够学到对方的loopback地址。 注重,每个客户之间毗连的地址是端口到端口的,如同两台路由器直接用线缆毗连,它们毗连的IP是统一个网段的。 运营商收集用台路由器,一台P,两台PE,每PE毗连VPNA和VPNB的各一个CE。两台PE经由过程L2TPV3为客户VPNA和VPNB实现端口到端口的二层VPN。 R1为P,R2和R3为PE;BT4破解无线收集密码教程 R7,R8为客户VPNA的CE; R9,R10为客户VPNB的CE; 运营商内部IGP为OSPF 1;VPNA 的IGP 为OSPF 64;VPNB 的 IGP为 RIPV2。 尝试完成后R7,R8能学到对方的loopback地址,以7.7.7.7为源ping通8.8.8.8; R9,R10能学到对方的loopback地址,以9.9.9.9为源ping通10.10.10.10。 具体尝试的拓扑如下: 2.尝试轨范 2.1设置装备摆设运营商IGP,设置装备摆设完后每台运营商路由器都能学到其他两台的loopback地址。 R1 interface Loopback0 ip address 1.1.1.1 255.255.255.255 !ubuntu 11.04 安装 interface Serial1/0 ip address 1.1.12.1 255.255.255.0 ! interface Serial1/1 ip … 继续阅读

1.尝试描述 有两个客户,一个VPNA,一个VPNB,经由过程运营收集成立端口到端口的二层VPN。VPNA的CE之间跑OSPF,VPNB的CE之间跑RIPV2。使得两个客户能够学到对方的loopback地址。 注重,每个客户之间毗连的地址是端口到端口的,如同两台路由器直接用线缆毗连,它们毗连的IP是统一个网段的。 运营商收集用台路由器,一台P,两台PE,每PE毗连VPNA和VPNB的各一个CE。两台PE经由过程L2TPV3为客户VPNA和VPNB实现端口到端口的二层VPN。 R1为P,R2和R3为PE;BT4破解无线收集密码教程 R7,R8为客户VPNA的CE; R9,R10为客户VPNB的CE; 运营商内部IGP为OSPF 1;VPNA 的IGP 为OSPF 64;VPNB 的 IGP为 RIPV2。 尝试完成后R7,R8能学到对方的loopback地址,以7.7.7.7为源ping通8.8.8.8; R9,R10能学到对方的loopback地址,以9.9.9.9为源ping通10.10.10.10。 具体尝试的拓扑如下: 2.尝试轨范 2.1设置装备摆设运营商IGP,设置装备摆设完后每台运营商路由器都能学到其他两台的loopback地址。 R1 interface Loopback0 ip address 1.1.1.1 255.255.255.255 !ubuntu 11.04 安装 interface Serial1/0 ip address 1.1.12.1 255.255.255.0 ! interface Serial1/1 ip address 1.1.13.1 255.255.255.0 ! router ospf 1 router-id 1.1.1.1 network 1.1.1.1 0.0.0.0 area 0 network 1.1.12.0 0.0.0.255 area 0 network 1.1.13.0 0.0.0.255 area 0 ! R2 interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! router ospf 1 router-id 2.2.2.2 log-adjacency-changes network 1.1.12.0 0.0.0.255 area 0 network 2.2.2.2 0.0.0.0 area 0 ! interface Serial1/0 ip address 1.1.12.2 255.255.255.0 ! R3 interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial1/0 ip address 1.1.13.3 255.255.255.0 !Ubuntu 输入法安装   router ospf 1 router-id 3.3.3.3 network 1.1.13.0 0.0.0.255 area 0 network 3.3.3.3 0.0.0.0 area 0 ! 以下内容需要回覆才能看到 验证每台运营商路由器都能学到其他路由器的loopback地址。 r1# sh ip route Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2 E1 – OSPF external type 1, E2 – OSPF external type 2 i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2 ia – IS-IS inter area, * – candidate default, U – per-user static route o – ODR, P – periodic downloaded static route Gateway of last resort is not set 1.0.0.0/8 is variably subnetted, 3 subnets, 2 masks C 1.1.1.1/32 is directly connected, Loopback0 C 1.1.12.0/24 is directly connected, Serial1/0 C 1.1.13.0/24 is directly connected, Serial1/1 2.0.0.0/32 is subnetted, 1 subnets O 2.2.2.2 [110/65] via 1.1.12.2, 01:20:13, Serial1/0 3.0.0.0/32 is subnetted, 1 subnets O 3.3.3.3 [110/65] via 1.1.13.3, 01:20:13, Serial1/1 r1# r2#sh ip route Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2 E1 – OSPF external type 1, E2 – OSPF external type 2 i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2 ia – IS-IS inter area, * – candidate default, U – per-user static route o – ODR, P – periodic downloaded static route Gateway of last resort is not set 1.0.0.0/8 is variably subnetted, 3 subnets, 2 masks O 1.1.1.1/32 [110/65] via 1.1.12.1, 01:20:27, Serial1/0 C 1.1.12.0/24 is directly connected, Serial1/0 O 1.1.13.0/24 [110/128] via 1.1.12.1, 01:20:27, Serial1/0 2.0.0.0/32 is subnetted, 1 subnets C 2.2.2.2 is directly connected, Loopback0 3.0.0.0/32 is subnetted, 1 subnets O 3.3.3.3 [110/129] via 1.1.12.1, 01:20:27, Serial1/0 r3#sh ip route Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2 E1 – OSPF external type 1, E2 – OSPF external type 2 i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2 ia – IS-IS inter area, * – candidate default, U – per-user static route o – ODR, P – periodic downloaded static route Gateway of last resort is not set 1.0.0.0/8 is variably subnetted, 3 subnets, 2 masks O 1.1.1.1/32 [110/65] via 1.1.13.1, 01:20:32, Serial1/0 O 1.1.12.0/24 [110/128] via 1.1.13.1, 01:20:32, Serial1/0 C 1.1.13.0/24 is directly connected, Serial1/0 2.0.0.0/32 is subnetted, 1 subnets O 2.2.2.2 [110/129] via 1.1.13.1, 01:20:32, Serial1/0 3.0.0.0/32 is subnetted, 1 subnets C 3.3.3.3 is directly connected, Loopback0 2.2设置装备摆设运营商两台PE的L2TPV3,设置装备摆设完后验证会话。 R2 pseudowire-class vpna //*界说一个摸版名为VPNA encapsulation l2tpv3 //*封装为l2tpv3 protocol none //* 因为设置装备摆设手动L2TPV3会话,这里禁用L2TPV3 ip local interface Loopback0 ! pseudowire-class vpnb encapsulation l2tpv3 protocol none ip local interface Loopback0 ! interface Ethernet0/0 no ip address half-duplex no cdp enable xconnect 3.3.3.3 33 encapsulation l2tpv3 manual pw-class vpna //*对等体ip地址为3.3.3.3 ,VCID为33,L2TPV3为手动模式,挪用摸版vpna l2tp id 245 329 //*l2tp当地会话ID为245,远程为329,在对等体设置与这里相反 l2tp cookie local 8 957344 93790092 //*界说L2TPV3cookies,呵护VC会话,对等体何处当地和远程cookies与这里相反 l2tp cookie remote 8 76429 945 ! interface Ethernet0/1 no ip address half-duplex no cdp enable xconnect 3.3.3.3 44 encapsulation l2tpv3 manual pw-class vpnb l2tp id 222 333 l2tp cookie local 8 444444 5555555 l2tp cookie remote 8 66666 666 ! R3 pseudowire-class vpna encapsulation l2tpv3 protocol none ip local interface Loopback0 ! pseudowire-class vpnb encapsulation l2tpv3 protocol none ip local interface Loopback0 ! interface Ethernet0/0 no ip address half-duplex no cdp enable xconnect 1.1.1.1 33 encapsulation l2tpv3 manual pw-class vpna l2tp id 329 245 l2tp cookie local 8 76429 945 l2tp cookie remote 8 957344 93790092 ! interface Ethernet0/1 no ip address half-duplex no cdp enable xconnect 2.2.2.2 44 encapsulation l2tpv3 manual pw-class vpnb l2tp id 333 222 l2tp cookie local 8 66666 666 l2tp cookie remote 8 444444 5555555 ! 用show l2tun显示会话摘要信息 r2#sh l2tun L2TP Tunnel and Session Information Total tunnels 0 sessions 2 LocID RemID TunID Username, Intf/ State Last Chg Uniq ID Vcid, Circuit 245 329 0 33, Et0/0 est 01:19:22 1 222 333 0 44, Et0/1 est 00:44:01 2 用show l2tun session all显示会话属性 r2#sh l2tun session all L2TP Session Information Total tunnels 0 sessions 2 Session id 245 is up, tunnel id 0 Call serial number is 0 Remote tunnel name is Internet address is 3.3.3.3 Session is manually signalled Session state is established, time since change 01:20:11 150061 Packets sent, 0 received 12060054 Bytes sent, 0 received Last clearing of “show vpdn” counters never Receive packets dropped: out-of-order: 0 total: 0 Send packets dropped: exceeded session MTU: 0 total: 0 Session vcid is 33 Session Layer 2 circuit, type is Ethernet, name is Ethernet0/0 Circuit state is UP Remote session id is 329, remote tunnel id 0 DF bit off, ToS reflect disabled, ToS value 0, TTL value 255 Session cookie information: local cookie, size 8 bytes, value 05 97 1F 8C 00 0E 9B A0 remote cookie, size 8 bytes, value 00 00 03 B1 00 01 2A 8D UDP checksums are disabled SSS switching enabled Sequencing is off Unique ID is 1 Session id 222 is up, tunnel id 0 Call serial number is 0 Remote tunnel name is Internet address is 3.3.3.3 Session is manually signalled Session state is established, time since change 00:44:51 73507 Packets sent, 33786 received 5879391 Bytes sent, 2673331 received Last clearing of “show vpdn” counters never Receive packets dropped: out-of-order: 0 total: 0 Send packets dropped: exceeded session MTU: 0 total: 0Linux 论坛 思科论坛 思科CCNP团购 评论这张 转发至微博





Published by
Published by xFruits
Original source : http://www.vpn123.tk/?p=223...

No comments:

Post a Comment