I am studying about IP fragmentation and MTU. What I know is MTU is the property of Physical medium, as in the amount of data it can process without having to fragment the data. The default MTU on machine is set to 1500. From reading on the web I understand that 28 bytes is reserved for ICMP so my actual MTU is 1472.
If I set DF bit to one and packet size to 1472, I get ping responses and I see traffic in Wireshark for the same
ping 8.8.8.8 -f -l 1472
Pinging 8.8.8.8 with 1472 bytes of data:
Reply from 8.8.8.8: bytes=68 (sent 1472) time=60ms TTL=113
Reply from 8.8.8.8: bytes=68 (sent 1472) time=67ms TTL=113
Reply from 8.8.8.8: bytes=68 (sent 1472) time=77ms TTL=113
Reply from 8.8.8.8: bytes=68 (sent 1472) time=44ms TTL=113
But if I ping with packet size 1473, I get below:
C:\Users\admin>ping 8.8.8.8 -f -l 1473
Pinging 8.8.8.8 with 1473 bytes of data:
Packet needs to be fragmented but DF set.
Packet needs to be fragmented but DF set.
Packet needs to be fragmented but DF set.
Packet needs to be fragmented but DF set.
I had a Wireshark running when I initiated this Ping but I never see this in Wireshark. How come this is not seen on Wireshark? I mean should I not see some ICMP response? I believe if the TCP/IP Stack on my machine sees that DF bit is set and MTU is exceeding then it will itself drop the packet? Can someone confirm?
Further, if I remove the DF flag then I do see ICMP pings in Wireshark but the ping fails:
C:\Users\admin>ping 8.8.8.8 -l 1473
Pinging 8.8.8.8 with 1473 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Why would this fail? I tried changing the MTU on my machine manually from 1500 to 1501
MTU MediaSenseState Bytes In Bytes Out Interface
------ --------------- --------- --------- -------------
4294967295 1 54991843 0 Loopback Pseudo-Interface 1
1500 5 0 0 Wi-Fi
1500 5 0 0 Ethernet
1500 5 0 0 Local Area Connection* 14
1500 5 0 0 Local Area Connection* 15
**1501 1 114787330 26005606 Ethernet 2**
1500 1 0 755762 VirtualBox Host-Only Network
Even after increasing the MTU I get Request time out. Can someone explain this? Is this because my machines capacity is still 1500 bytes and changing it to 1500 will not have any effect?