01-05-2012 01:16 AM - edited 03-07-2019 04:11 AM
Hi Cisco experts,
I'm using a Catalyst 4948. It seems to drop all truncated packets. I don't know whether this is an expected behavior.
I'm developing a program which processes packets in the following steps:
1) capture packets
2) if a packet is too long, truncate it to a certain length
3) insert a vlan tag (say 100) to each packet
4) send them to the switch
Mac address learning is disabled on the vlan 100, so the packets should be seen at all ports of the vlan. However, I only observed untruncated packets. Truncated packets seemed to be dropped by the switch.
The summary of the source port is:
c4948-01#show interfaces gigabitEthernet 1/22 summary
......
Interface IHQ IQD OHQ OQD RXBS RXPS TXBS TXPS TRTL
-------------------------------------------------------------------------
* GigabitEthernet1/22 0 0 0 0 4018000 7390 2000 3 0
The receiving speed was approximately equal to what I sent.
The summary of another vlan 100 port is:
c4948-01#show interfaces gigabitEthernet 1/18 summary
......
Interface IHQ IQD OHQ OQD RXBS RXPS TXBS TXPS TRTL
-------------------------------------------------------------------------
* GigabitEthernet1/18 0 0 0 0 0 0 3000 4 0
Almost no packets were output.
I see a Cisco document says "ingress port drops corrupted packets" (http://www.cisco.com/en/US/products/hw/switches/ps708/products_tech_note09186a008015c612.shtml#topic8-6), then my questions are:
1) Is this the root cause of dropping truncated packets?
2) What criteria does a switch use to check corrupted packets? My understanding is that truncated packets could have wrong L3 and L4 data, but they can't be detected at L2.
3) If switch drops mal-format packets, can we disable this feature?
Thanks!
01-05-2012 01:36 AM
Hi Wang,
I guess you cannot trunkate a packet.. when you truncate it, it is treated as corrupted packet and dropped by the switch. The MTU decides how much byte can be transmitted and if the packet is more than that, then you have to Fragment the Data.
Just my 2 cents.. will let experts to clarify.
-Vijay
01-05-2012 06:17 PM
Hi Vijya, thanks for your reply.
Truncating is a required feature of my application, so I can't use fragment.
I just wonder how a switch checks packets. I think a L2 switch doesn't check L3 info. If some powerful switches can do this kind of check, it should be a optional feature that can be enabled/disabled by users. Does Cisco provide a knob to control this check?
Thanks!
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