IT技术互动交流平台

思科路由器实现双出口NAT负载均衡和备份

作者:Linux 防火墙  发布日期:2012-06-15 09:46:26


R2#show running-config
Building configuration...

Current configuration : 1779 bytes
!
version 12.2
service timestamps debug uptime
service timestamps log uptime
no service password-encryption
!
hostname R2
!
enable secret 5 $1$xz5X$osuW46yqKGwoGl9NhQlrS1
!
ip subnet-zero
!
!
no ip domain-lookup
!
!
!
!
interface FastEthernet0/0
ip address 172.16.1.7 255.255.255.0
ip nat inside
ip policy route-map lanqi
duplex auto
speed auto
!
interface Serial1/0
description to ISP_A
ip address 74.1.1.7 255.255.255.0
ip nat outside
serial restart-delay 0
!
interface Serial1/1
description to ISP-B
ip address 75.1.1.7 255.255.255.0
ip nat outside
serial restart-delay 0
www.it165.net
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
ip nat inside source route-map cisco1 interface Serial1/0 overload
ip nat inside source route-map cisco2 interface Serial1/1 overload
ip nat inside source route-map cisco3 interface Serial1/1 overload
ip nat inside source route-map cisco4 interface Serial1/0 overload
ip classless
ip route 0.0.0.0 0.0.0.0 74.1.1.4
ip route 0.0.0.0 0.0.0.0 75.1.1.5
ip route 172.16.2.0 255.255.255.0 172.16.1.3
ip http server
!
access-list 1 permit 172.16.1.0 0.0.0.255
access-list 2 permit 172.16.2.0 0.0.0.255
route-map cisco4 permit 10
match ip address 2
!
route-map cisco1 permit 10
match ip address 1
match interface Serial1/0
!
route-map cisco3 permit 10
match ip address 2
match interface Serial1/1
!
route-map cisco2 permit 10
match ip address 1
!
route-map lanqi permit 10
match ip address 1 s1/0
set interface Serial1/0
!
route-map lanqi permit 20
match ip address 2
match interface Serial1/1
set interface Serial1/1
!
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
exec-timeout 0 0
password cisco
login   
!
end
 

  • 专题推荐

About IT165 - 广告服务 - 隐私声明 - 版权申明 - 免责条款 - 网站地图 - 网友投稿 - 联系方式
本站内容来自于互联网,仅供用于网络技术学习,学习中请遵循相关法律法规