cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
8603
Views
35
Helpful
10
Replies

what happenes with Frame when CRC / FCS failes

AdamBudzinski
Level 1
Level 1

 

hi all,

 

Consider he following simple environment. Laptop 1 sends an Ethernet 2  frame to PC2. Laptop1 will calculate the CRC value and place it in the FCS field of the frame. Let's assume Switch1 is configured with the "Store-and-forward" mode. 

Case 1. After Switch1 receives and buffers the whole Frame, it calculates it's CRC value and compares it with the value in the FCS filed. They DO NOT match.  Switch 1  discards the frame. 

 

Question a) If it gets discarded i will not see it in a network analyzer like Wireshark. How can I check on a Switch for FCS errors / how many frames it dropped because of CRC mismatch ? 

Question b) Will the Switch notify Laptop1 that it dropped the Frame, or will it be completely up to the Layerk 4 protocol on Laptop1 side to handle this issue ? What i mean prior to exchanging data, Laptop1 and PC2 established a connection (3 way handshake). So Laptop1 will send data with the sequence number let's say 0123 and since it didn't get any ACK for that SEQ number from PC2 because the frame was dropped by the switch , it will be the Laptop 1 that will re-send the frame ? 

 

Case 2. The Frame reaches PC2 and because of CRC mismatch it being dropped by the PC2 NIC. How can i check if this was caused by CRC issues ? 

 

I hope it all makes sense and i was able to put it in words.

 

Thank you for any help !

 

Best Regards

 

Adam 

10 Replies 10

Richard Burts
Hall of Fame
Hall of Fame

Adam

 

In case 1 where the frame is dropped by the switch there is no notification sent. It is up to the software in PC1 to detect that it was dropped and to deal with it (probably by retransmission).

 

In case 2 where the frame is dropped by the PC then you would need to check the NIC and the interface of the PC.

 

HTH

 

Rick

HTH

Rick

Peter Paluch
Cisco Employee
Cisco Employee

Hi Adam,

Nice to meet you again!

Question a) If it gets discarded i will not see it in a network analyzer like Wireshark. How can I check on a Switch for FCS errors / how many frames it dropped because of CRC mismatch ? 

There are show commands to reveal these kinds of issues.

Switch# show interfaces fa0/1
FastEthernet0/1 is down, line protocol is down (notconnect)
  Hardware is Fast Ethernet, address is 0023.34ed.9683 (bia 0023.34ed.9683)
  MTU 1500 bytes, BW 10000 Kbit, DLY 1000 usec,
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation ARPA, loopback not set
  Keepalive set (10 sec)
  Auto-duplex, Auto-speed, media type is 10/100BaseTX
  input flow-control is off, output flow-control is unsupported
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/40 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog, 0 multicast, 0 pause input
     0 input packets with dribble condition detected
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 1 interface resets
     0 babbles, 0 late collision, 0 deferred
     0 lost carrier, 0 no carrier, 0 PAUSE output
     0 output buffer failures, 0 output buffers swapped out

 

Switch# show interfaces fa0/1 counters errors

Port        Align-Err     FCS-Err    Xmit-Err     Rcv-Err  UnderSize  OutDiscards
Fa0/1               0           0           0           0          0            0

Port      Single-Col  Multi-Col   Late-Col  Excess-Col  Carri-Sen      Runts     Giants
Fa0/1              0          0          0           0          0          0          0

 

Switch# show controllers ethernet-controller fa0/1

     Transmit FastEthernet0/1                 Receive
            0 Bytes                                0 Bytes                    
            0 Unicast frames                       0 Unicast frames           
            0 Multicast frames                     0 Multicast frames         
            0 Broadcast frames                     0 Broadcast frames         
            0 Too old frames                       0 Unicast bytes            
            0 Deferred frames                      0 Multicast bytes          
            0 MTU exceeded frames                  0 Broadcast bytes          
            0 1 collision frames                   0 Alignment errors         
            0 2 collision frames                   0 FCS errors               
            0 3 collision frames                   0 Oversize frames          
            0 4 collision frames                   0 Undersize frames         
            0 5 collision frames                   0 Collision fragments      
            0 6 collision frames       
            0 7 collision frames                   0 Minimum size frames      
            0 8 collision frames                   0 65 to 127 byte frames    
            0 9 collision frames                   0 128 to 255 byte frames   
            0 10 collision frames                  0 256 to 511 byte frames   
            0 11 collision frames                  0 512 to 1023 byte frames  
            0 12 collision frames                  0 1024 to 1518 byte frames
            0 13 collision frames                  0 Overrun frames           
            0 14 collision frames                  0 Pause frames             
            0 15 collision frames      
            0 Excessive collisions                 0 Symbol error frames      
            0 Late collisions                      0 Invalid frames, too large
            0 VLAN discard frames                  0 Valid frames, too large  
            0 Excess defer frames                  0 Invalid frames, too small
            0 64 byte frames                       0 Valid frames, too small  
            0 127 byte frames          
            0 255 byte frames                      0 Too old frames           
            0 511 byte frames                      0 Valid oversize frames    
            0 1023 byte frames                     0 System FCS error frames  
            0 1518 byte frames                     0 RxPortFifoFull drop frame
            0 Too large frames         
            0 Good (1 coll) frames     
            0 Good (>1 coll) frames    

These outputs were captured on a Catalyst 3560. These commands would also apply to 2960 and 3750 series switches. Other platforms may have slightly different commands and their outputs but there should always be a way of getting these values.

Question b) Will the Switch notify Laptop1 that it dropped the Frame, or will it be completely up to the Layerk 4 protocol on Laptop1 side to handle this issue ?

No, the switch will silently discard the frame without notifying anyone. Ethernet has no signalling that would allow one device to tell the other that the frame has been damaged or discarded. The frame will be lost without a trace, and it is up to higher protocols (in TCP/IP, up to TCP or SCTP) to correct the resulting information loss.

What i mean prior to exchanging data, Laptop1 and PC2 established a connection (3 way handshake). So Laptop1 will send data with the sequence number let's say 0123 and since it didn't get any ACK for that SEQ number from PC2 because the frame was dropped by the switch , it will be the Laptop 1 that will re-send the frame ? 

You are talking about a TCP session between Laptop1 and PC2 here. In this case, yes, you are correct: Because Laptop1 will get no acknowledgement for the data it sent to PC2, it will - after a certain period of time - re-send the unacknowledged TCP segment that will get encapsulated into an IP packet and ultimately into an Ethernet frame as it is sent out from Laptop1's NIC.

Case 2. The Frame reaches PC2 and because of CRC mismatch it being dropped by the PC2 NIC. How can i check if this was caused by CRC issues ? 

This depends on whether the operating system on PC2 maintains any statistics regarding its NIC operation. When a NIC drops a frame because of some error condition, it will signal this in some of its internal registers that the NIC driver can access and collect information from. The question is, though, whether the operating system collects this information. Being a Linux guy, I cannot really speak for Windows, but in Linux, these data are to be seen in various places. For example, if my WiFi adapter is called wlan0 under Linux, the statistics can be seen as individual files in the /sys/class/net/wlan0/statistics directory. Another file holding these data for all network cards in system is the /proc/net/dev file.

Perhaps someone more acquainted with Windows can tell us if there is a way of accessing these counters under that OS.

Best regards,
Peter

 

Hi Peter,

 

nice to hear from you too ! 

 

Thank you for taking time to answer he questions. Clear and very informative as always :).

 

if you don't mind, I would like to ask few more questions. From your experience, how often would you have to look for CRC errors? I mean, let's consider the  above diagram where I have a backup software running on a physical server attached to the switch on one end, and other servers that I'm going to backup on the other end of the switch. Let's assume, we have performance issues during backup (slow rate) for on server (out of 5). Would i high level of CRC errors on the switch port (comparing to  other switch ports with a way lover CRC errors count) indicate strait away a possible hardware issue? (I assume yes).

 

 

Also, question in regards of Link Speed & Duplex settings. What is the best practice to configure it ? Should it be left to auto negotiation or should I hard set the link speed and duplex settings to match on the servers network cards + on the switch ports involved? 

 

What would be the "result" of connecting a server with a 100 Mbps NIC to a 1000 Mbps switch port ? 

 

Thank you in advance and have a great week ! 

 

 

Best Regards

 

Adam 

Disclaimer

The Author of this posting offers the information contained within this posting without consideration and with the reader's understanding that there's no implied or expressed suitability or fitness for any purpose. Information provided is for informational purposes only and should not be construed as rendering professional advice of any kind. Usage of this posting's information is solely at reader's own risk.

Liability Disclaimer

In no event shall Author be liable for any damages whatsoever (including, without limitation, damages for loss of use, data or profit) arising out of the use or inability to use the posting's information even if Author has been advised of the possibility of such damage.

Posting

How often do you look for CRC errors? 

Ideally, all the time (using some kind of network monitoring that will "flag" them if they occur).

Would a high level of CRC errors indicate a hardware problem?

Often it does.  Generally, CRC error percentage should be rather low.  How low?

Well look at one of my prod 10g interfaces:

Last clearing of "show interface" counters 44w1d
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 482999000 bits/sec, 51263 packets/sec
5 minute output rate 95867000 bits/sec, 10791 packets/sec
L2 Switched: ucast: 0 pkt, 0 bytes - mcast: 0 pkt, 0 bytes
L3 in Switched: ucast: 0 pkt, 0 bytes - mcast: 0 pkt, 0 bytes mcast
L3 out Switched: ucast: 0 pkt, 0 bytes mcast: 0 pkt, 0 bytes
   1154891261515 packets input, 1351108668330815 bytes, 0 no buffer
   Received 940415694 broadcasts (641762082 multicasts)
   0 runts, 1697456530 giants, 0 throttles
   0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
   0 watchdog, 0 multicast, 0 pause input
   0 input packets with dribble condition detected
   215351446850 packets output, 212990037453404 bytes, 0 underruns
   0 output errors, 0 collisions, 0 interface resets
   0 babbles, 0 late collision, 0 deferred
   0 lost carrier, 0 no carrier, 0 PAUSE output
   0 output buffer failures, 0 output buffers swapped out

Compare the number of packets received and the number of CRC errors.

 

Regarding speed/duplex settings, on modern equipment, best practice is auto/auto.  Only hard code if auto is found not to work.

 

"What would be the "result" of connecting a server with a 100 Mbps NIC to a 1000 Mbps switch port ? "

Depends on the switch's port.  If the switch port is only gig, and the server port only 100, they won't work.  More likely, switch port is "triple speed", so it should fall back to 100 and work.

Hi Joseph,

thank you for your answer ! 

"What would be the "result" of connecting a server with a 100 Mbps NIC to a 1000 Mbps switch port ? "

Depends on the switch's port.  If the switch port is only gig, and the server port only 100, they won't work.  More likely, switch port is "triple speed", so it should fall back to 100 and work.

 

 

And what about the above scenario (please have a look at the diagram). There is data exchange between Laptop1 and PC2. The speed / duplex settings will me negotiated between Laptop1 - switch, and  switch PC2 ? Or between Laptop1 and PC2? 

 

Best Regards

 

Adam 

Hi Adam,

And what about the above scenario (please have a look at the diagram). There is data exchange between Laptop1 and PC2. The speed / duplex settings will me negotiated between Laptop1 - switch, and  switch PC2 ? Or between Laptop1 and PC2? 

The duplex and speed is always negotiated between directly connected link partners. In your case, a separate speed/duplex would be negotiated between the Laptop1 and its port on the switch, and a separate speed/duplex setting would be negotiated between PC2 and its port on the switch.

Best regards,
Peter

Hi Peter,

 

so basically Laptop1 - switch is one link, switch to PC2 is another link. So, when Laptop1 - Switch negotiate a 1000Mbps/full duplex connection but  switch to PC2   100Mbps/full duplex (because, let's say the PC2's NIC is hard coded to 100 Mbps) , the throughput will not be faster than the link between switch and PC2, so this is what CISCO tries to say in their materials, right ? 

 

In an internetwork or network with multiple segments, throughput cannot be faster than the slowest link of the path from source to destination. Even if all or most of the segments have high bandwidth, it will only take one segment in the path with low throughput to create a bottleneck to the throughput of the entire network.

 

 

Best Regards

 

Adam 

Hi Adam,

So, when Laptop1 - Switch negotiate a 1000Mbps/full duplex connection but  switch to PC2   100Mbps/full duplex (because, let's say the PC2's NIC is hard coded to 100 Mbps) , the throughput will not be faster than the link between switch and PC2

Correct.

so this is what CISCO tries to say in their materials, right ? 

Basically yes. The quotation talks about "a bottleneck to the throughput of the entire network" which is overly general. Surely, a single slow link is not going to slow down the entire network just because it is there. A slow link is going to slow down the communication of anyone whose data are passed through that link. Obviously, data not passing through that link are not subject to its bottleneck.

Best regards,
Peter

Hi Peter,

 

makes sense.

Just one more question. In the above scenario, would be iperf the best tool/way to check maximum throughput between Laptop1 and PC2 ? Or are there other ways to check it ? 

 

Best Regards

 

Adam 

Hi Adam,

In the above scenario, would be iperf the best tool/way to check maximum throughput between Laptop1 and PC2 ? Or are there other ways to check it ? 

If you want to measure true throughput then you would need to use some sort of traffic generator, such as iperf. Without doing the actual measurement, you can only do a prediction. Whether the iperf is the best tool could be a matter of debate as there are several traffic generators available, but for simple purposes, iperf would certainly be okay to use.

Best regards,
Peter

Review Cisco Networking products for a $25 gift card