10-29-2015 12:54 PM - edited 03-08-2019 02:29 AM
I am trying to incorporate a layer 3 switch into a network. (see diagram 1 below). My problem is that in the configuration below, the layer 3 switch seems to offer no additional benefits over a layer 2 switch as it does not switch layer 3 packets, instead it will need an additional router configuring.
If i configure the 2 interfaces as no switchports, (diagram2) and create virtual interfaces on the layer 3 switch, ie g0/0.1, g0/0.2, g0/0.3, g0/1.1,g0/1.2, g0/1.3, configure encapsulation dot1q, and add ip addresses and subnets on each interface, then I understand I can use the layer 3 switch as a router.
However this now introduces a new problem, VLAN 1 is on both interfaces, therefore devices in VLAN 1 on each interface will have to point to the default gateway on that specific interface and VLAN 1 devices on the G0/0.1 interface will have to be configured with a different subnet than those on the G0/1.1 interface.
This does not seem logical, Am I missing something ?
Diagram 1
Solved! Go to Solution.
10-29-2015 01:42 PM
Paul
On a L3 switch you don't configure subinterfaces (usually).
You create what are called SVIs (Switched Virtual Interfaces) instead and these are your L3 interfaces.
So ports on your L3 switch are L2 ports either trunks or assigned to specific vlans.
Then for each vlan you want to route you create an SVI ie. -
int vlan <x>
ip address x.x.x.x <subnet mask>
no shut
and the default gateway of clients in that vlan is the IP assigned to the SVI.
Any other L3 interface configuration you add to the SVI.
The only time you really use L3 ports is when you connect to a router for example.
Jon
10-29-2015 01:06 PM
Configure VTP domain and instead of sub interface use vlan intefaces on layer 3 switch..
10-29-2015 01:20 PM
Doesnt VTp just ensure that all switches have the same VLANS listed. how does that have any bearing on this issue ?
10-29-2015 01:27 PM
Well, if you keep them in vtp domain and use vlan interface, you can use secondary IP address on vlan1.
int vlan1
ip address 192.168.0.254 255.255.255.0
ip address 192.168.1.254 255.255.255.0 secondary
/
10-29-2015 01:42 PM
Paul
On a L3 switch you don't configure subinterfaces (usually).
You create what are called SVIs (Switched Virtual Interfaces) instead and these are your L3 interfaces.
So ports on your L3 switch are L2 ports either trunks or assigned to specific vlans.
Then for each vlan you want to route you create an SVI ie. -
int vlan <x>
ip address x.x.x.x <subnet mask>
no shut
and the default gateway of clients in that vlan is the IP assigned to the SVI.
Any other L3 interface configuration you add to the SVI.
The only time you really use L3 ports is when you connect to a router for example.
Jon
10-29-2015 01:45 PM
Aha of course, so i set up trunks as per diagram 1 and simply create SVI's for each VLAN with the IP address that will be used as the gateway device.
thanks Jon
10-29-2015 01:49 PM
No problem and yes that is exactly what you do.
Jon
10-29-2015 01:52 PM
One last thing about SVIs.
They will only come up if either -
1) an access port connected to that vlan on the switch is up/up
or
2) an trunk link allowing that vlan is up/up.
Just in case they aren't coming up.
Jon
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide