双出口nat配置(一主一备)

双出口情况:同时连接两家isp的拓扑。



实验目录:

1、配置双出口的注意点。

2、实现主备链路切换。


实验配置:

1)各接口IP的配置略,R5上有指向R2的默认路由,

R3、R4运行OSPF

router ospf 1
 log-adjacency-changes
 network 0.0.0.0 255.255.255.255 area 0    \\直接将所有网段通告了。

为了更清晰说明nat过程与默认路由选择过程,所以在第1)步中将R3与R4之间接口6.6.6.0/24状态都配置为down

接下来主要看R2配置

R2(config)#do sh run

interface Ethernet0/0
 ip address 1.1.1.2 255.255.255.0
 ip nat outside
 ip virtual-reassembly
 half-duplex
!
interface Ethernet0/1
 ip address 10.45.1.1 255.255.255.0
 ip nat outside
 ip virtual-reassembly
 half-duplex
!
interface Ethernet0/2
 no ip address
 shutdown
 half-duplex
!
interface Ethernet0/3
 ip address 192.168.1.1 255.255.255.0
 ip nat inside
 ip virtual-reassembly
 half-duplex
!
no ip http server
no ip http secure-server
!
ip forward-protocol nd
ip route 0.0.0.0 0.0.0.0 10.45.1.3
ip route 0.0.0.0 0.0.0.0 1.1.1.1
!
ip nat inside source route-map isp_a interface Ethernet0/0 overload   \\通过上一章《思科多Nat顺序》实验知道,分组被nat时要通过整个nat列表顺序(sh run时)过滤的,第一条匹配不再执行第二条。
ip nat inside source route-map isp_b interface Ethernet0/1 overload
!
access-list 100 permit ip any any
!
route-map isp_a permit 10
 match ip address 100
 match interface Ethernet0/0  \\匹配接口,强制nat的出口࿰

  • 6
    点赞
  • 13
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值