cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
8324
Views
5
Helpful
7
Replies

Layer 2 ( Switch) and fragmentation

sarahr202
Level 5
Level 5

Hi everybody,

My curiosity again kicked in.

Router f1/1----------f1Swf2------REST OF NETWORK

Above router and SW are IOS based, SW is layer 2.

Router:

int f1/1

mtu 1530 ( router is IOS based, so mtu 1530 represents the L3 payload  for layer 2)

ip mtu 1530

SW:

F2:

mtu 1500

Let say R1 sends a packet of size 1510 bytes, ( which means the whole frame with be 1524 bytes with 14 bytes for L2 header), SW receives it and perform a  mac look up which dictates frame must be forwarded out of f1  which has MTU of 1500 bytes.

What will SW do next? will it fragment it because F2's  MTU is lower than the packet size 1510 bytes?

I do not find any docs that describe fragmentation by Layer 2 switch.  LAB on GNS3 shows no fragmentation but it can not be taken as concrete  evidence as GNS3 has shown many non standard behavior.

Have a nice weekend!!

1 Accepted Solution

Accepted Solutions

Richard Burts
Hall of Fame
Hall of Fame

Interesting question. Fragmentation is a layer 3 function where the IP header can contain information indicating that fragmentation has occurred and whether this packet is the last packet or not. Layer 2 switches do not process transit frames at layer 3. So layer 2 switches can not fragment. If the frame received by the switch is too large to send through the outbound interface the layer 2 switch will drop the frame.

HTH

Rick

HTH

Rick

View solution in original post

7 Replies 7

Richard Burts
Hall of Fame
Hall of Fame

Interesting question. Fragmentation is a layer 3 function where the IP header can contain information indicating that fragmentation has occurred and whether this packet is the last packet or not. Layer 2 switches do not process transit frames at layer 3. So layer 2 switches can not fragment. If the frame received by the switch is too large to send through the outbound interface the layer 2 switch will drop the frame.

HTH

Rick

HTH

Rick

Hi Rick,

That is my hunch was too. 

On the different note, there are a lot of functions not traditionally associate with layer 2 but layer 2 switch are coded to perform those additional functions for e.g some layer 2  switch can  filter traffic on IP/UDP/TCP  

But you have a good very good point:  IP layer is responsible for fragmentation ( setting up off set, more fragments bits), also IP layer determines when to fragment the packet.

Much appreciated !!

Have a good day.

Yes I agree that there are increasing number of functions that used to be associated with routers that are now performed by switches as well. And my first reaction in reading your question was to wonder if fragmentation might fall into that category. But a brief review of fundamental principles (where is the fragmentation information in the frame) led me to the conclusion that layer 2 can not perform fragmentation. It was an interesting thought process.

HTH

Rick

HTH

Rick

And my first reaction in reading your question was to wonder if fragmentation might fall into that category

That exactly what prompted me to post the question; somehow I missed the basic fragmentation principles .

Appreciate your help.

Speaking of thought processes, I was thinking perhaps a "super smart" switch could fragment a L3 packet even when there's no L3 interface.  I don't know of any switch that does, but in theory, I haven't thought of a reason why it couldn't be done.  In practice, it might be a bit of a bother to implement (especially in hardware) and likely not much market demand for such a feature.

Maybe I'm wrong but for me it doesn't make sense to have a switch able to fragment L3 packets. If it was  the case, then it would be a routed ports and become the source of sending packets (and the node that fragment, as the source of sending)

Yes, a L3 switch, using a L3 port can fragment. However, what I was suggesting, as many L2 switches incorporate L3 features, in theory a "smart" L2 switch could too. However, if packet had the DF bit set, don't know whether a L2 switch could logically construct the notification ICMP packet.
Review Cisco Networking products for a $25 gift card