Jump to content


1

Difference between L2 and L3 Switch


14 replies to this topic

#1 Abhijithblack

Abhijithblack

    Member

  • Members
  • PipPip
  • 33 posts
  • 1 thanks

Posted 08 October 2008 - 09:48 AM

What are main difference between L2 and L3 switch?
How we can identify the switch whether it is L2 or L3?
what are the difference in configuration?
can we restrict the bandwidth in L2 switch?
how we can restrict the bandwidth in switch and what are the commands are being used?

Please give me details for the above questions

#2 Naresh

Naresh

    Advanced Member

  • Members
  • PipPipPip
  • 52 posts
  • 117 thanks

Posted 08 October 2008 - 11:35 AM

Quote

What are main difference between L2 and L3 switch?
How we can identify the switch whether it is L2 or L3?
what are the difference in configuration?
can we restrict the bandwidth in L2 switch?
how we can restrict the bandwidth in switch and what are the commands are being used?

Please give me details for the above questions

L2 switches are used in midsize org where as L3 used at Enterprise n/w or at ISP's end. L2 switches are cost effective comparatively L3
The number of ports available on L3 will be more comp to L2.
L3 switches mainly used for Failover and Loadbalance

Just google for L3 switches to know more or you can use cisco.com for further details...
L3 switches have more commands and options comparatively L2.
With the VLAN's you are doing the same task of bandwidth limitation(:confused: Is am wrong)
CCNA 640-802
CCNA Security 640-553
MCSA 2003
MCTS Network Infrastructure


Next......................... 70-297

#3 IPsec88

IPsec88

    Advanced Member

  • Members
  • PipPipPip
  • 177 posts
  • 480 thanks

Posted 08 October 2008 - 11:43 AM

the main difference is the routing
it's like their name
switching is a L2 task and L2 switches are able to just switch packets.
but routing is a L3 task and L3 switches can do routing jobs too like a router.
in access layer we use L2 switches wherease in distribution and core layer we use layer 3 switches.

#4 Naresh

Naresh

    Advanced Member

  • Members
  • PipPipPip
  • 52 posts
  • 117 thanks

Posted 08 October 2008 - 04:29 PM

Quote

the main difference is the routing
it's like their name
switching is a L2 task and L2 switches are able to just switch packets.
but routing is a L3 task and L3 switches can do routing jobs too like a router.
in access layer we use L2 switches wherease in distribution and core layer we use layer 3 switches.

YEP.....   but do the switches do routing ?????  Rather than Router no device do routing  ( any one ready to debate :cool:)
CCNA 640-802
CCNA Security 640-553
MCSA 2003
MCTS Network Infrastructure


Next......................... 70-297

#5 amol0009in_7

amol0009in_7

    Member

  • Members
  • PipPip
  • 41 posts
  • 10 thanks

Posted 08 October 2008 - 04:53 PM

[quote='Naresh' pid='18987' dateline='1223483363']
[quote='IPsec88' pid='18941' dateline='1223466234']
YEP.....   but do the switches do routing ?????  Rather than Router no device do routing  ( any one ready to debate :cool:)
[/quote]

My Friend nowdays u run bgp ,ospf  every damn routing protocol on switch.They do routing
|2006 -Desktop & Networking L1 | 2007-CCNA | 2008-BCMSN[CCNP] | 2008-CCSA

| 2009 Feb-BSCI[CCNP](next target) | 2009 Dec-CCIE Written(queued) | 2040 - A CEO of company

#6 IPsec88

IPsec88

    Advanced Member

  • Members
  • PipPipPip
  • 177 posts
  • 480 thanks

Posted 08 October 2008 - 06:07 PM

yes mate, L3 switches do routing.
for example consider this situation related to inter-vlan routing:
you have a switch and on that switch you have 4 Vlans (each vlan use a separate subnet Network).
If a client on vlan1 need to communicate with another client on Vlan2 and your switch is L2 you need a router for doing the routing and make inter-vlan routing possible.
but if the switch is L3 you can do the routing on the switch and you do not need to buy a router.
what is known as a Layer 3 switch, in fact can make decisions based on Layer 3 information but can still also make decisions based on Layer 2 information depending on how the switch is configured. I suppose in the case of a Layer 3 switch that is performing only Layer 3 forwarding and not Layer 2, it could be classed as a router.
and you should also know that L3 switch process packets in hardware (using ASICs) while routers in software (using microprocessor).

hope it helps

#7 Screeeeeem

Screeeeeem

    IT Freak!!!

  • Administrators
  • 729 posts
  • 129 thanks

Posted 08 October 2008 - 06:18 PM

Basically a layer 2 switch operates utilizing Mac addresses in it's caching table to quickly pass information from port to port. A layer 3 switch utilizes IP addresses to do the same.

While the previous explanation is the "What", for folks in networking the following "How" is far more interesting.

Essentially, A layer 2 switch is essentially a multiport bridge. A layer 2 switch will learn about MAC addresses connected to each port and passes frames marked for those ports. It also knows that if a frame is sent out a port but is looking for the MAC address of the port it is connected to and drop that frame. Whereas a single CPU Bridge runs in serial, todays hardware based switches run in parallel, translating to extremly fast switching.

Layer 3 switching is a hybrid, as one can imagine, of a router and a switch. There are different types of layer 3 switching, route caching andtopology-based. In route caching the switch required both a Route Processor (RP) and a Switch Engine (SE). The RP must listen to the first packet to determine the destination. At that point the Switch Engine makes a shortcut entry in the caching table for the rest of the packets to follow. Due to advancement in processing power and drastic reductions in the cost of memory, today's higher end layer 3 switches implement a topology-based switching which builds a lookup table and and poputlates it with the entire network's topology. The database is held in hardware and is referenced there to maintain high throughput. It utilizes the longest address match as the layer 3 destination.

Now when and why would one use a l2 vs l3 vs a router? Simply put, a router will generally sit at the gateway between a private and a public network. A router can perform NAT whereas an l3 switch cannot (imagine a switch that had the topology entries for the ENTIRE Internet!!). In a small very flat network (meaning only one private network range for the whole site) a L2 switch to connect all the servers and clients to the internet is probably going to suffice. Larger networks, or those with the need to contain broadcast traffic or those utilizing VOIP, a multi network approach utilizing VLANs is appropriate, and when one is utilizing VLANs, L3 switches are a natural fit. While a router on a stick scenario can work, it can quickly overtax a router if there is any significant intervlan traffic since the router must make complicated routing decisions for every packet that it recieves.

Under Construction.....


#8 nicomakz

nicomakz

    Normal User

  • Members
  • PipPipPip
  • 53 posts
  • 41 thanks

Posted 10 October 2008 - 12:13 AM

Quote

... A router can perform NAT whereas an l3 switch cannot (imagine a switch that had the topology entries for the ENTIRE Internet!!).

Hey, Screeeeem, I didn´t get that! It gives the idea that to do NAT a device should have the topology for the entire Internet??? Most routers that can do NAT do not have the means to manage entire Internet topology either.

Well, I like this question, it is so frequent!

The answer to the question "What is the difference between a L2 and L3 switch?"

Well, easy one: Layer 3 switches DO NOT EXIST!

Let me summarize some points already discussed here:
  • Switches are Layer 2 devices
  • Routers are Layer 3 devices
  • Layer 3 switches do routing (yes, they DO, but they do not exist, right?)

Well, like Screeeeem said, Layer 3 switches are hybrids. In fact, a Layer 3 switch is a box with BOTH a switch and a router (or at least a router engine).

And no, Layer 3 switches do not do things like a regular switch, except since the point of view of an outside observer, ie, if you have a frame that should go elsewhere IN YOUR LAN, both devices (Layer 2 or Layer 3 Switches) will do their jobs. A main difference, however,  is HOW they do that, and usually SPEED is associated with L3 switches (after all, let´s use their names!)

What L3 Switches do is an evolution of using ASICs (or electronics) to decide what interfaces would the switch use to forward frames. With ASICs (and Layer 2 Switches, such as most people know switching), critical information is stored in hardware, making it possible to move information at high speeds (thats another marketing term: "at wire speed"). Without ASICs, the device should process (uses processor, an expensive and somewhat slow resource), and the decision would not be as fast as with ASICs.

The evolution I mentioned is related to doing similar things as just explained, but using IP addresses instead of MAC addresses! One of the technologies used for that end is CEF, or Cisco Express Forwarding.

If L3 switches can route, why should someone buy a router instead of a L3 switch? Well, an L3 Switch comes with a "reduced version" of a router, and they are more apropriate (thus the marketing idea behind the fancy name of "Layer 3 Switch") in a LAN environment where you have a couple (or lots) of VLANS!

In other words, they are ideal to route between VLANs, so you don´t have to buy routers and switches separately!

HTH

#9 Screeeeeem

Screeeeeem

    IT Freak!!!

  • Administrators
  • 729 posts
  • 129 thanks

Posted 10 October 2008 - 04:31 PM

tht sentence just means u cant replace the router with a L3 switch :D

Under Construction.....


#10 SS

SS

    Elite Member

  • Administrators
  • 5019 posts
  • 11926 thanks

Posted 10 October 2008 - 04:49 PM

BTW

Posted Image

[align=justify]The ProCurve Switch 6200yl-24G-mGBIC is an advanced Layer 3 stackable in 1U height. It has 24 mini-GBIC slots and an expansion slot for an optional 4-port 10-GbE module. Designed to be deployed as an aggregator of traffic from the edge to the core of the network, this switch supports a variety of Gigabit mini-GBICs, such as SX, LX, LH, and 1000Base-T. The foundation for this switch is a purpose-built ProVision ASIC that allows the most demanding networking features, such as QoS and security, to be implemented in a scalable yet granular fashion. With its high-performance architecture, 10-GbE capability, and programmable ASIC, this switch offers excellent investment protection, flexibility, and scalability.



What Is a Layer 3 Switch?


A Layer 3 switch is a high-performance device for network routing. Layer 3 switches actually differ very little from routers. A Layer 3 switch can support the same routing protocols as network routers do. Both inspect incoming packets and make dynamic routing decisions based on the source and destination addresses inside. Both types of boxes share a similar appearance.

Layer 3 switches were conceived as a technology to improve on the performance of routers used in large local area networks (LANs) like corporate intranets. The key difference between Layer 3 switches and routers lies in the hardware technology used to build the unit. The hardware inside a Layer 3 switch merges that of traditional switches and routers, replacing some of a router's software logic with hardware to offer better performance in some situations.

Layer 3 switches often cost less than traditional routers. Designed for use within local networks, a Layer 3 switch will typically not possess the WAN ports and wide area network features a traditional router will always have.[/align]
http://twitter.com/certcollection

#11 nicomakz

nicomakz

    Normal User

  • Members
  • PipPipPip
  • 53 posts
  • 41 thanks

Posted 12 October 2008 - 12:00 PM

Well, except for the product part, the rest is once again confirming what we said previously.

Nice to know that HP has a product line with some Layer 3 switches, and even its name (since we are in a Cisco forum!)

#12 SS

SS

    Elite Member

  • Administrators
  • 5019 posts
  • 11926 thanks

Posted 12 October 2008 - 12:10 PM

No problem

Manufacturer   Cisco Systems, Inc
Manufacturer Part Number WS-C4948-10GE-E
Manufacturer Website Address www.cisco.com
Product Line Catalyst
Product Series 4900
Product Name Catalyst 4948 10GE Enhanced Managed Layer 3 Ethernet Switch
Product Type Layer 3 Switch

Posted Image
http://twitter.com/certcollection

#13 nicomakz

nicomakz

    Normal User

  • Members
  • PipPipPip
  • 53 posts
  • 41 thanks

Posted 12 October 2008 - 12:24 PM

Quote

No problem

Posted Image

No, it is not really a problem... but this we are more familiar with, and so more happy now! :biggrin:

Thanks for the image!

#14 besmart

besmart

    Advanced Member

  • Members
  • PipPipPip
  • 57 posts
  • 1095 thanks

Posted 18 October 2008 - 08:09 AM

So, if you  plan to build VLAN , you must go to layer 3 switches , else use layer2 switch.
The question is why VLAN?
simply:
1) to minimize collision at switch ports and enhance LAN performance.
2) if you have 255+ users within LAN , you must build VLANs based on hierarchy model  using distribution switches as Layer3 , and Access switches as layer2 switch.
3)you can also use that model for less number of users , if you take scalability into account.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Organization

Community

Downloads

Test Providers

Site Info


Go to top