2

When a router receives a padded 64 byte Ethernet II(aka DIX) frame and it needs to send this over an dot1q sub-interface, then router will add a new Ethernet II header, IEEE 802.1q field and recalculate the FCS. The question is, should router put a 64 byte frame onto wire or 68 byte frame? For example router receives an ICMP "echo request" message which has 6+6+2 byte DIX header, 20 byte IPv4 header, 8 byte ICMP header, padding of zeros for 14 bytes and then the 4 byte FCS. Now if the router will forward this frame over 802.1q sub-interface, which means that 4-byte 802.1q field is added, then should the router preserve all the padding and send 68 byte frame to wire or should it cut off 4-bytes of padding and send the 64 byte frame? A reference to RFC would be great.

4

Routers work at layer-3. Your ICMP message would be extracted from it's layer-2 container (which is bigger than the l3 payload) and processed as such. The next-hop would be presented 28 bytes to be encoded for whatever layer-2 it might be. Thus, in theory, a 64byte padded frame would be transmit.

In a switch, yes, an 802.1q tag would be inserted into the otherwise as-is frame. (adding 4 bytes.)

  • I say "in theory" because a router that builds the frame and then tags it would emit a 68byte frame. I've never actually looked at what my various tech does. – Ricky Beam Jan 20 '15 at 22:32
  • Could you please explain this "The next-hop would be presented 28 bytes to be encoded for whatever layer-2 it might be"? – Martin Jan 20 '15 at 22:47
  • ROUTERS don't shuffle ethernet frames around, that's the realm of SWITCHES. A router will act on the 28 byte IP (ICMP) payload. – Ricky Beam Jan 21 '15 at 2:08
  • I see. So the routers will (1) add a new Ethernet II encapsulation to 28 bytes(20 byte IPv4 header and 8 byte ICMP header), (2) add 4 byte IEEE 802.1q filed, (3) pad the frame so it is 60 bytes in length, (4) calculate the CRC using the entire 60 bytes and (5) adds the calculated 32 bit value to the Ethernet II frame as a FCS field so that in total the frame is 64 bytes in length? – Martin Jan 21 '15 at 8:23
2

While DIX can't tell the exact payload length when padding is used, a router is going to decapsulate the IP packet. When it is forwarded, the packet is encapsulated with a minimum payload requirement of 42 octets. So 64 octets should be send out at layer 2 on the dot1q interface.

Of course, it's entirely possible that one or two vendors don't vary the padding ... so I would include the same "in theory" caveat as Ricky.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.