策略路由实验,指定出口_第1张图片

 

要达到的效果就是
192.168.0.1 从 g0/0 100.0.0.1 网络出去
192.168.1.1 从 g0/1 200.0.0.1 网络出去
192.168.2.1 从 g0/2 210.0.0.1 网络出去

 

board add 0/10 24GE
#
snmp-agent local-engineid 800007DB03000000000000
snmp-agent
#
clock timezone China-Standard-Time minus 08:00:00
#
portal local-server load flash:/portalpage.zip
#
drop illegal-mac alarm
#
vlan batch 10 20 30
#
wlan ac-global carrier id other ac id 0
#
set cpu-usage threshold 80 restore 75
#
acl number 2000
rule 5 permit source 192.168.10.0 0.0.0.255
acl number 2001
rule 5 permit source 192.168.20.0 0.0.0.255
acl number 2002
rule 5 permit source 192.168.30.0 0.0.0.255
#
traffic classifier 20 operator or
if-match acl 2001
traffic classifier 10 operator or
if-match acl 2000
traffic classifier 30 operator or
if-match acl 2002
#
traffic behavior 20
redirect ip-nexthop 200.0.0.2
traffic behavior 10
redirect ip-nexthop 100.0.0.2
traffic behavior 30
redirect ip-nexthop 210.0.0.2
#
traffic policy 20
classifier 20 behavior 20
traffic policy 10
classifier 10 behavior 10
traffic policy 30
classifier 30 behavior 30
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password cipher %$%$K8m.Nt84DZ}e#<0`8bmE3Uw}%$%$
local-user admin service-type http
#
firewall zone Local
priority 15
#
interface Vlanif10
ip address 192.168.10.1 255.255.255.0
traffic-policy 10 inbound
#
interface Vlanif20
ip address 192.168.20.1 255.255.255.0
traffic-policy 20 inbound
#
interface Vlanif30
ip address 192.168.30.1 255.255.255.0
traffic-policy 30 inbound
#
interface GigabitEthernet0/0/0
ip address 210.0.0.1 255.255.255.0
#
interface GigabitEthernet0/0/1
ip address 100.0.0.1 255.255.255.0
#
interface GigabitEthernet0/0/2
ip address 200.0.0.1 255.255.255.0
#
interface GigabitEthernet10/0/0
#
interface GigabitEthernet10/0/1
port link-type access
port default vlan 10
#
interface GigabitEthernet10/0/2
port link-type access
port default vlan 20
#
interface GigabitEthernet10/0/3
port link-type access
port default vlan 30
#
interface GigabitEthernet10/0/4
#
interface GigabitEthernet10/0/5
#
interface GigabitEthernet10/0/6
#
interface GigabitEthernet10/0/7
#
interface GigabitEthernet10/0/8
#
interface GigabitEthernet10/0/9
#
interface GigabitEthernet10/0/10
#
interface GigabitEthernet10/0/11
#
interface GigabitEthernet10/0/12
#
interface GigabitEthernet10/0/13
#
interface GigabitEthernet10/0/14
#
interface GigabitEthernet10/0/15
#
interface GigabitEthernet10/0/16
#
interface GigabitEthernet10/0/17
#
interface GigabitEthernet10/0/18
#
interface GigabitEthernet10/0/19
#
interface GigabitEthernet10/0/20
#
interface GigabitEthernet10/0/21
#
interface GigabitEthernet10/0/22
#
interface GigabitEthernet10/0/23
#
interface NULL0
#
user-interface con 0
authentication-mode password
user-interface vty 0 4
user-interface vty 16 20
#
wlan ac
#
return