我所要实现的效果为,通过ADSL拨号上网,ADSL猫接CISCO2600 E0/0接口,E0/1接内部网,要求E0/1能共享E0/0上网
总结了一下,配置一共有8个步骤
- 配置VPDN
-
vpdn enable //启用VPDN
-
no vpdn logging
-
vpdn-group TEST //建立一个VPDN组
-
request-dialin //初始化VPDN隧道
-
protocol pppoe(使用pppoe建立会话隧道)
-
- 配置E0/0
- int e0/0
- pppoe enable //允许以太接口运行pppoe
- pppoe-client dial-pool-number 1 //将以太接口的pppoe拨号客户端加入拨号池1
- 配制ADSL端口
- int ATM0
- no ip address
- no atm ilmi-keepalive
- bundle-enable
- dsl operating-mode auto
- hold-queue 224 in
- interface ATM0.1 point-to-point //ADSL的通讯 依靠VC,所以必须设定点到点VC
- pvc 8/35 //设置PVC的相关参数, 即VCI和VPI的值,如果不清楚请向局端查询
- pppoe-client dial-pool-number 1 //PPPoE拨号进程使用了常规的拨号进程,这里引用了dialer-pool 1
- 配置逻辑接口
- int dialer 1
- ip address negotiated //从adsl服务商动态协商得到ip地址
- mtu 1492 //定义帧大小
- encapsulation ppp //为该接口封装ppp协议
- dialer pool 1 该接口使用1号拨号池进行拨号
- ppp authentication pap callin //启用ppp pap验证
- ppp pap sent-username dial_username password dial_password //发送用户名和密码
- IP nat outside
- 配置内部接口
- int e0/1
- ip add 192.168.0.1 255.255.255.0
- ip nat inside
- 配置DHCP
- ip dhcp excluded-address 192.168.0.1
- ip dhcp pool test
- network 192.168.0.0 255.255.255.0
- default-router 192.168.0.1
- dns-server 192.168.0.1
- 配置NAT
- access-list 1 permit 192.168.0.0 0.0.0.255
- ip nat inside source list 1 interface dialer1 overload
- 配置路由
- ip route 0.0.0.0 0.0.0.0 dialer1