Cisco1841路由器连接ADSL modem的PPPoE配置

之前做的实验:

Building configuration...

Current configuration : 1693 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R1
!
boot-start-marker
boot-end-marker
!
enable secret 5 $1$V5pL$owc4RoTcJqywXPP0CoF1i.
!
no aaa new-model
ip cef
!
!
no ip dhcp use vrf connected
ip dhcp excluded-address 192.168.1.1 192.168.1.99
ip dhcp excluded-address 192.168.1.200 192.168.1.254
!
ip dhcp pool lan
network 192.168.1.0 255.255.255.0
dns-server 202.96.128.166 202.96.134.133
default-router 192.168.1.1
!
ip dhcp pool client1
host 192.168.1.100 255.255.255.0
client-identifier 0100.0000.0000.00
!
!
no ip domain lookup
multilink bundle-name authenticated
vpdn enable
!
vpdn-group oceano
request-dialin
protocol pppoe
!
!
!
username ming privilege 15 password 0 123456
archive
log config
hidekeys
!
!
!
!
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
pppoe enable
pppoe-client dial-pool-number 1
!
interface FastEthernet0/1
ip address 192.168.1.1 255.255.255.0
ip nat inside
ip virtual-reassembly
duplex auto
speed auto
!
interface Dialer1
ip address negotiated
ip mtu 1492
ip nat outside
ip virtual-reassembly
encapsulation ppp
dialer pool 1
dialer-group 1
ppp authentication pap callin
ppp pap sent-username xxxxxx@163.gd password 0 12345678
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 Dialer1
!
!
ip http server
ip http authentication local
ip nat inside source list 1 interface Dialer1 overload
!
access-list 1 permit 192.168.1.0 0.0.0.255
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
logging synchronous
login local
line aux 0
line vty 0 4
login local
transport input all
!
scheduler allocate 20000 1000
end


注意MTU配置为1492

参考:

第一步:配置vpdn
vpdn enable(启用路由器的虚拟专用拨号网络---vpnd)

vpdn-group office(建立一个vpdn组,)

request-dialin(初始化一个vpnd tunnel,建立一个请求拨入的vpdn子组,)

protocol pppoe(vpdn子组使用pppoe建立会话隧道)

第二步: 配置路由器连接adsl modem的接口
interface Ethernet1

no ip address

pppoe enable允许以太接口运行pppoe

pppoe-client dial-pool-number 1将以太接口的pppoe拨号客户端加入拨号池1

第三步:配置逻辑拨号接口:
interface Dialer1

ip address negotiated从adsl服务商动态协商得到ip地址

ip nat outside为该接口启用NAT

encapsulation ppp为该接口封装ppp协议

dialer pool 1该接口使用1号拨号池进行拨号

dialer-group 1该命令对于pppoe是意义不大的

ppp authentication pap callin启用ppp pap验证

ppp pap sent-username xxxxxxx password 0 yyyyyyy使用已经申请的用户名和口令

第四步:配置内部网络接口
interface Ethernet0(内部网络接口)

ip address 10.1.1.1 255.255.255.0

ip nat inside为该接口启用NAT

第五步:配置路由器为内部网络主机提供dhcp服务
ip dhcp excluded-address 10.1.1.1

ip dhcp pool ABC

import all(导入dns和wins server)

network 10.1.1.0 255.255.255.0

default-router 10.1.1.1

第六步:配置NAT:
access-list 1 permit 10.1.1.0 0.0.0.255

ip nat inside source list 1 interface Dialer1 overload



第七步:配置缺省路由
ip route 0.0.0.0 0.0.0.0 Dialer









本文转自pimg200551CTO博客,原文链接: http://blog.51cto.com/pimg2005/834969,如需转载请自行联系原作者




上一篇:Eureka高可用注册中心搭建


下一篇:网页浏览器选项卡、窗口、标签区别