您的位置:首页 > 其它

思科路由器配置nat实现内网中两台web服务器的负载平衡

2012-10-18 08:52 495 查看


配置文件:
interface fastethernet0/1
ip address 192.168.0.1 255.255.0.0 //定义局域网端口IP地址
duplex auto
speed auto
ip nat inside //定义为局域端口
!
interface serial 1/0
ip address 222.92.36.1 255.255.255.0 //定义广域网端口IP地址
duplex auto
speed auto
ip nat outside //定义为广域端口
!
access-list 1 permit 222.92.36.2 //定义轮询地址列表1
!
ip nat pool websev 192.168.0.100 192.168.0.110 255.255.255.0 type rotary
//定义Web服务器的IP地址池,Rotary关键字表示准备使用轮询策略从NAT池中取出相应的IP地址用于转换进来的IP报文,访问222.92.36.2的请求将依次被发送给192.168.0.100-110.
ip nat inside destination list 1 pool websev
// inside destination list语句定义与列表1相匹配的IP地址的报文将使用轮询策略
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息