三层交换机上配置 VRRP :
配置步骤:
1.配置PC
2.配置交换机
接入层交换机-SW3
核心层交换机-SW1/2
#首先配置 VLAN
sw1/2/3:
vlan batch 10 20 -> 同时创建 vlan 10 / 20 ;
#其次配置 SW3 与 PC 的互联
sw3:
interface gi0/0/1
port link-type access
port default vlan 10
interface gi0/0/2
port link-type access
port default vlan 20
#再次配置 SW3 与 SW1/2 的互联:
SW3:
interface gi0/0/13
port link-type trunk
port trunk allow-pass vlan all
interface gi0/0/23
port link-type trunk
port trunk allow-pass vlan all
SW1:
interface gi0/0/13
port link-type trunk
port trunk allow-pass vlan all
SW2:
interface gi0/0/23
port link-type trunk
port trunk allow-pass vlan all
#最后配置 vlan 10 与 vlan 20 的网关IP ,并启用 VRRP
SW1:
interface vlanif 10
ip address 192.168.10.251
255.255.255.0
vrrp vrid 10 virtual-ip 192.168.10.250
vrrp vrid 10 priority 150
interface vlanif 20
ip address 192.168.20.251
255.255.255.0
vrrp vrid 20 virtual-ip 192.168.20.250
SW2:
interface vlanif 10
ip address 192.168.10.252
255.255.255.0
vrrp vrid 10 virtual-ip 192.168.10.250
interface vlanif 20
ip address 192.168.20.252
255.255.255.0
vrrp vrid 20 virtual-ip 192.168.20.250
vrrp vrid 20 priority 150
原文:http://blog.51cto.com/11806823/2156615