?
Solved

Usage of Layer2/Layer3 Switch

Posted on 2009-05-10
21
Medium Priority
?
303 Views
Last Modified: 2012-05-06
As far as I know, Layer 2 switch can be split into Vlans and those Vlans will form different subnets, and the L2 switch can be trunked from one port to the router port to make all the vlans talk to each other.
Layer 3 switch, from what I have heard it works like a router, but how it does.??
If I have a LAyer 3 switch with 48 ports.Does that mean I can create Vlans and will be able to talk to each other without a need for  trunk to the router?

Thanks
0
Comment
Question by:jskfan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 10
  • 7
  • 4
21 Comments
 
LVL 23

Assisted Solution

by:that1guy15
that1guy15 earned 880 total points
ID: 24350344
You are correct. A L3 switch is basically a switch and router combined. You can create VLANs on it and then also route between the VLANs without the use of a router.

An L3 switch is able to do this because it stores both a L2 mac address table (CAM table) and a L3 routing table (FIB table). You can also utilize L3 routing protocols on a L3 switch such as OSPF, EIGRP (cisco only), BGP and others.

0
 
LVL 50

Accepted Solution

by:
Don Johnston earned 1120 total points
ID: 24350713
Be careful of the term Layer 3 switch. There aren't many layer 3 switches anymore. A true layer 3 switch is nothing more than a very fast router with only ethernet ports. The devices that most people mean when they say "Layer 3 Switch" is actually a multilayer switch. Capable of layer 2 and layer 3 operations.

The easiest way to think about a multilayer switch is to first start out with a regular layer 2 switch that has all the normal features of a layer 2 switch (VLANs, trunks, etherchannel, spanning-tree, etc.).

Then put a router inside of the switch. The connection between the router and the switch is over the internal backplane of the switch (usually measured in multi-gigabit speed). that can carry all VLANs.

For intra-VLAN traffic, the standard layer-2 switching operations are performed. But inter-VLAN traffic is sent to the (internal) router to handle.


0
 

Author Comment

by:jskfan
ID: 24352785
is there any series number that Multi layer switch starts from, so that we can tell if it's multi layer switch or layer2 just by koojing at it from outside the box?
when you configure routing between vlans in layer, you need to specify which port is a trunk and which vlans can route traffic through that trunk.
 how do you do that in layer 3.?
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 50

Expert Comment

by:Don Johnston
ID: 24353260
>is there any series number that Multi layer switch starts from

No. In the Cisco product line, the layer 3 switches end with "L3". As in 3548G-L3.

> how do you do that in layer 3.?

Same way you do with a router. Remember, a layer three switch IS a router. Just really fast. :-)
0
 

Author Comment

by:jskfan
ID: 24353750
in routers, if I remember you create a sub-interface for each vlan, is it the same in L3 switch?
L3 switch might have just ethernet ports, how do you do that?
if you don't mind please paste the code on how to configure Vlans to talk to each other.
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24353801
>                Was this comment helpful?                         Yes               No                                 jskfan:             in routers, if I remember you create a sub-interface for each vlan, is it the same in L3 switch?

Yes.

>L3 switch might have just ethernet ports, how do you do that?
None of Cisco's Layer3 switches have ethernet ports. Only FastEthernet and GigabitEthernet ports.

>if you don't mind please paste the code on how to configure Vlans to talk to each other.
On a layer 3 switch? Just like you do on a router.

int f0/1.1
 encap dot1q 1
 ip address x.x.x.x y.y.y.y
int f0/1.2
 encap dot1q 2
 ip address x.x.x.x y.y.y.y

etc.
0
 

Author Comment

by:jskfan
ID: 24353892
<<ip address x.x.x.x y.y.y.y>>>

is it gonna be the same as the IP address configured on  the VLAN interface?
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24353945
What VLAN interface?
0
 

Author Comment

by:jskfan
ID: 24354014
on the switch you are going to create a VLAN (VLAN10) and add tghe rnage of ports to it, then assign it an IP address. (10.10.10.10)
in the router subinterface you are going to create a trunk port and give it the same address as 10.10.10.10 ???
if you don't mind try to paste the code on ho wto create vlans on the switch, assign ithem IPs and how to trunk them to a router subinterface.
that's a lot but I appreciate it.
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24354059
On a layer 2 switch you don't assign IP addresses to VLANs. It's a layer TWO switch. The only IP address on a layer 2 switch is for management.

0
 

Author Comment

by:jskfan
ID: 24354148
canyou just drop the code here on ho wto create vlans on a switch and how to trunk them to the router?
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24354159
vlan 10
vlan 20
vlan 30
int f0/1
 switchport trunk encap dot1q
 switchport mode trunk

0
 

Author Comment

by:jskfan
ID: 24354233
I know that it takes time to type the whole configuration.
whenever you get a chance can you do it? no rush..
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24354268
No.

To create a full config for your switch would require more information. The topology of the network (what devices are connected to what ports, IP addresses, etc., etc., etc.,).

Way beyond the scope this question and format.
0
 

Author Comment

by:jskfan
ID: 24354340
you can just set up an example:
Switch1 has 24 ports we nee 3 vlans of 5 ports each, to talk to each other. That's it.
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24354381
What model switch?
What version IOS?
What are the VLANs (numbers)?
What ports will be in what VLANs?
What port will be connected to the router?
What model router?
What version IOS?
What port will be connected to the switch?
Will the router be connected to any other devices?

0
 
LVL 23

Expert Comment

by:that1guy15
ID: 24356121
Oh a whole lot going on here!! Lets take a step back for a second and see if we can get this solved.

Creating VLANs on a L3 switch is done the exact same way as an L2 switch. In fact VLANs and ports on an L3 switch only run at L2 until you configure them to run at layer three.

donjohnston was correct on how to create the VLANs and set them up as trunk ports. But on a L3 switch you do not need to create sub-interfaces and trunk VLANs. All you need to do is set the VLAN up with an IP address. This creates a SVI (switched virtual interface) for the vlan that runs at layer three and allows traffic to flow between VLANs. The IP address should reside in the same subnet as the VLAN and all devices in the VLAN should point to that IP for a gateway. That is all that needs to be done to route VLANs on a L3 switch.

Oh forgot you must first enable IP routing :)

Here is a sample of what it would look like with two VLANs

vlan 100
vlan 200 <---creates the vlans
interface range f0/1 - 5
switchport mode access
switchport access vlan 100 <---assignees port 1 - 5 to vlan 100

interface range f0/6 - 12
switchport mode access
switchport access vlan 200 <---assigness port 6 - 12 to vlan 200

ip routing <---enables IP routing

int vlan 100
no switchport <---enables L3 capabilities
ip address 10.0.0.1 <--this will be VLAN 100s default gateway

int vlan 200
no switchport
ip address 10.0.100.1


Traffic will now be able to flow between vlan 100 and 200.
0
 
LVL 23

Expert Comment

by:that1guy15
ID: 24356138
woops correction:

int vlan 100
no switchport <---enables L3 capabilities
ip address 10.0.0.1 255.255.255.0<--this will be VLAN 100s default gateway

int vlan 200
no switchport
ip address 10.0.100.1 255.255.255.0
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24356158
>Creating VLANs on a L3 switch is done the exact same way as an L2 switch.

You cannot create VLANs on a layer-3 switch. You can only do this on a layer-2 and a multi-layer switch.

0
 
LVL 23

Expert Comment

by:that1guy15
ID: 24356239
donjohnston:

I think we are using two different terms for the exact same thing. When I say L3 switch i mean a multi-layer switch such as a 3550 or 3560.

0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 24356537
> When I say L3 switch i mean a multi-layer switch such as a 3550 or 3560.

And that can create some confusion.
0

Featured Post

Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an OSPF network that automatically (dynamically) reroutes network traffic over other connections to prevent network downtime.
Quality of Service (QoS) options are nearly endless when it comes to networks today. This article is merely one example of how it can be handled in a hub-n-spoke design using a 3-tier configuration.
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question