AR1200使用策略路由配置雙出口(isp)接入

2015/3/3 16:45:29點擊:
問題描述

AR1200使用策略路由配置雙wan(isp)接入

解決方案

 

http://support.huawei.com/enterprise/product/images/e7efe31266b94ee999161cde858dd0e3

AR1200配置如下:

#

acl number 3000           用于NAT

 rule 10 permit ip

#

acl number 3001             用于NAT

 rule 10 permit ip

#

acl number 3002                       (策略)定義基于端口的acl

 rule 10 permit ip source 192.168.10.0 0.0.0.255

#

traffic classifier c1              (策略) 定義流量配置

if-match acl 3002

#

traffic behavior b1               (策略)定義流量動作(zuò)

redirect ip-nexthop 2.2.2.1      移動的網關地址

#

traffic policy p1               (策略)組成流量策略

classifier c1 behavior b1

#

interface Ethernet0/0/0               與S5700互聯的IP地址

 ip address 192.168.30.2 255.255.255.0  配置內(nèi)網與S5700互聯IP地址

traffic-policy p1 inbound       (策略)應用流量策略,如果IP-nexthop地址不可(kě)達,策略路由将失效

#

interface GigabitEthernet0/0/0

 ip address 1.1.1.50 255.255.255.0  模拟電(diàn)信IP地址

 nat outbound 3000             做(zuò)Nat轉換

#

interface GigabitEthernet0/0/1

 ip address 2.2.2.10 255.255.255.0    模拟移動IP地址

 nat outbound 3001

#

ip route-static 0.0.0.0 0.0.0.0 1.1.1.1   默認路由指向電(diàn)信的網關地址

ip route-static 0.0.0.0 0.0.0.0 2.2.2.1 preference 150

       如果電(diàn)信斷了,會(huì)切到移動

ip route-static 192.168.10.0 255.255.255.0 192.168.30.1

 指向S5700的明(míng)細路由

ip route-static 192.168.20.0 255.255.255.0 192.168.30.1

指向S5700的明(míng)細路由

 

#

S5700配置示例如下:

#

ip route-static 0.0.0.0 0.0.0.0 192.168.30.2   配置将所有(yǒu)流量轉給路由器(qì)

#

interface Vlanif10                        vlan 10下接PC

 ip address 192.168.10.1 255.255.255.0   配置vlan10的網關地址

 dhcp select interface                     配置接于接口的dhcp

 dhcp server dns-list 8.8.8.8            配置dns

#

interface Vlanif20                          vlan20是會(huì)下挂PC

 ip address 192.168.20.1 255.255.255.0

#

interface Vlanif30                            vlan30作(zuò)為與路由器(qì)互聯的vlan

 ip address 192.168.30.1 255.255.255.0     與路由器(qì)互聯的Ip地址

#

interface GigabitEthernet0/0/1          配置與路由器(qì)互聯的IP接口

 port link-type access

 port default vlan 30