GNS3桥接modem拨号and QOS限速
?
今天在GNS3上面通過Cisco 3600路由器橋接PC模擬ADSL撥號
PC通過Loopback 環回口與R2 fa1/0連接,R2 fa0/0通過橋接到PC真實網卡上撥號
拓撲圖如下
?
?
R2主要配置如下:
ip cef
mls?qos? //QOS限速必須開啟
vpdn enable //啟用VPDN全局
!
interface FastEthernet0/0
?no ip address
?duplex auto
?speed auto
?pppoe enable group global?? ///啟用PPPOE撥號
?pppoe-client dial-pool-number 1 //綁定撥號池
!
interface FastEthernet1/0
?ip address 172.16.1.1 255.255.255.0
?ip nat inside? //開啟NAT
ip virtual-reassembly
?duplex auto
?speed auto
!
interface Dialer0? //撥號主要配置
?mtu 1492? //MTU大小(看當地電信MTU值 一般都是1480-1500)
?ip address negotiated? //IP地址自動獲取
?ip nat outside //NAT開啟
?ip virtual-reassembly? //IP虛擬分片重組
?ip virtual-reassembly max-reassemblies 32?//IP虛擬分片重組最大個樹32
?encapsulation ppp? //啟用PPP封裝驗證
?dialer pool 1?//關聯地址池
?dialer-group 1?//關聯接口刺激撥號
?ppp pap sent-username?Cixla password 0 110 //ADSL賬號和密碼
!
ip route 0.0.0.0 0.0.0.0 Dialer0 //默認出口路由
!
ip nat inside source list 1 interface Dialer0 overload //PAT規則
!
access-list 1 permit any
dialer-list 1 protocol ip permit? //抓取PPPOE感興趣流
?
成功撥號如下:
show interface dialer 0
?
show ip int br
?
show ip route
?PC上測試:
?
?
?
QOS限速(限制下載速度不超過64KB)
access-list 102 permit ip 172.16.1.0 0.0.0.255 any
access-list 102 permit ip any 172.16.1.0 0.0.0.255
?
?class-map match-all 172
?match access-group 102
!
!
policy-map QOS1
?class 172
? police cir 512000 //限速64KB
??? conform-action transmit
??? exceed-action drop
!
interface FastEthernet1/0? ///NAT inside方向
?ip address 172.16.1.1 255.255.255.0
?ip nat inside
?ip virtual-reassembly
?duplex auto
?speed auto
?service-policy input QOS1
?service-policy output QOS1
查看有沒匹配ACL
或者采用CAR?? 限速
rate-limit output access-group 102 512000 8000 16000 conform-action transmit exceed-action drop
效果一樣
轉載于:https://blog.51cto.com/leadlxx/725439
總結
以上是生活随笔為你收集整理的GNS3桥接modem拨号and QOS限速的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: java内部类基础(静态内部类)
- 下一篇: QQ组件可导致IE10无响应