static routes

Answered Question
Mar 11th, 2008

I have inter vlan routing configured on my switch. The switch is directly connected to the router. On the router I have static routes to the switch, the static routes point to the management vlan. My question is should I have each static route point the vlan interfaces or to the management vlan, in which case is vlan 1 in my config. Which method is better or correct? any performance differences? Or either one is correct? Thanks for the assistance!!!

here is the config

the port between switch and router is a physical port, " no switchport"

router ethernet 1/0

ip address 172.21.19.1 255.255.255.0


switch with inter-vlan routing

vlan 1 172.21.19.0 255.255.255.0 mangement

vlan 23 172.23.0.0 255.255.0.0

vlan 20 172.20.0.0 255.255.0.0

Correct Answer by Jon Marshall about 8 years 11 months ago

Hi


There are probably 2 ways to approach this


1) Create a dedicated vlan for the router to switch connection and use a /30 eg.


router


eth1/0

ip address 192.168.5.1 255.255.255.252


int vlan 3

ip address 192.168.5.2 255.255.255.252


and then put the port that the router connects to in vlan 3. Then your routes are


ip route 172.23.0.0 255.255.255.0 192.168.5.2

ip route 172.23.0.0 255.255.0.0 192.168.5.2

ip route 172.20.0.0 255.255.0.0 192.168.5.2


or


2) Pretty much the same as above except instead of using a dedicated vlan make the port that the router connects to a L3 routed port ie. on the switch


int fa0/10

no switchport

ip address 192.168.5.2 255.255.255.252


And then add routes as in 1



You can of course run a routing protocol between the L3 switch and the router.


As for the options i would go with option 2 if possible.


HTH


Jon

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Loading.
Correct Answer
Jon Marshall Tue, 03/11/2008 - 13:37

Hi


There are probably 2 ways to approach this


1) Create a dedicated vlan for the router to switch connection and use a /30 eg.


router


eth1/0

ip address 192.168.5.1 255.255.255.252


int vlan 3

ip address 192.168.5.2 255.255.255.252


and then put the port that the router connects to in vlan 3. Then your routes are


ip route 172.23.0.0 255.255.255.0 192.168.5.2

ip route 172.23.0.0 255.255.0.0 192.168.5.2

ip route 172.20.0.0 255.255.0.0 192.168.5.2


or


2) Pretty much the same as above except instead of using a dedicated vlan make the port that the router connects to a L3 routed port ie. on the switch


int fa0/10

no switchport

ip address 192.168.5.2 255.255.255.252


And then add routes as in 1



You can of course run a routing protocol between the L3 switch and the router.


As for the options i would go with option 2 if possible.


HTH


Jon

Istvan_Rabai Tue, 03/11/2008 - 13:40

Hi Bart,


I removed my message, as I can see Jon already answered.


Cheers:

Istvan

Actions

This Discussion