配置R1:R1(config)#username xmws password wisdomR1(config)#bba-group pppoe ToR2R1(config-bba-group)#virtual-template 1R1(config-bba-group)#exitR1(config)#interface ethernet0/0R1(config-if)#pppoe enable group ToR2R1(config-if)#no shutdownR1(config-if)#exitR1(config)#interface virtual-template 1R1(config-if)#ip address 12.1.1.1 255.255.255.252R1(config-if)#ip mtu 1492R1(config-if)#peer default ip address pool PoR2R1(config-if)#ppp authentication chapR1(config-if)#exitR1(config)#ip local pool PoR2 12.1.1.2R1(config)#endR1#
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
配置R2:R2(config)#interface ethernet0/0R2(config-if)#pppoe enableR2(config-if)#pppoe-client dial-pool-number 1R2(config-if)#no shutdownR2(config-if)#exitR2(config)#interface dialer 1 R2(config-if)#ip mtu 1492R2(config-if)#dialer pool 1R2(config-if)#ip address negotiatedR2(config-if)#encapsulation pppR2(config-if)#ppp ipcp route defaultR2(config-if)#ppp chap hostname xmwsR2(config-if)#ppp chap password wisdomR2(config-if)#endR2#
?
步驟3:檢查PPPoE
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
檢查R2:R2#show ip interface briefInterface IP-Address OK? Method Status ProtocolEthernet0/0 unassigned YES unset up up Ethernet0/1 192.168.1.254 YES manual up up Ethernet0/2 192.168.2.254 YES manual up up Ethernet0/3 unassigned YES unset administratively down down Serial1/0 unassigned YES unset administratively down down Serial1/1 unassigned YES unset administratively down down Serial1/2 unassigned YES unset administratively down down Serial1/3 unassigned YES unset administratively down down Dialer1 12.1.1.2 YES IPCP up up Virtual-Access1 unassigned YES unset up up Virtual-Access2 unassigned YES unset up up
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
R2#show ip routeCodes: L - local, 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, H - NHRP, l - LISP a - application route + - replicated route, % - next hop override, p - overrides from PfRGateway of last resort is 12.1.1.1 to network 0.0.0.0S* 0.0.0.0/0 [1/0] via 12.1.1.1 12.0.0.0/32 is subnetted, 2 subnetsC 12.1.1.1 is directly connected, Dialer1C 12.1.1.2 is directly connected, Dialer1 192.168.1.0/24 is variably subnetted, 2 subnets, 2 masksC 192.168.1.0/24 is directly connected, Ethernet0/1L 192.168.1.254/32 is directly connected, Ethernet0/1 192.168.2.0/24 is variably subnetted, 2 subnets, 2 masksC 192.168.2.0/24 is directly connected, Ethernet0/2L 192.168.2.254/32 is directly connected, Ethernet0/2
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
?
R2#show interfaces dialer 1Dialer1 is up, line protocol is up (spoofing) Hardware is Unknown Internet address is 12.1.1.2/32 MTU 1492 bytes, BW 56 Kbit/sec, DLY 20000 usec, reliability 255/255, txload 1/255, rxload 1/255 Encapsulation PPP, LCP Closed, loopback not set Keepalive set (10 sec) DTR is pulsed for 1 seconds on reset Interface is bound to Vi2 Last input never, output never, output hang never Last clearing of "show interface" counters 00:20:57 Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0 Queueing strategy: fifo Output queue: 0/40 (size/max) 5 minute input rate 0 bits/sec, 0 packets/sec 5 minute output rate 0 bits/sec, 0 packets/sec 6 packets input, 84 bytes 250 packets output, 3500 bytesBound to:Virtual-Access2 is up, line protocol is up Hardware is Virtual Access interface MTU 1492 bytes, BW 56 Kbit/sec, DLY 20000 usec, reliability 255/255, txload 1/255, rxload 1/255 --More--