PMTU (Path MTU) Discovery
Some Servers Are Unusable for Many Internet Uses
Summary
Internet Computers, Mostly Servers, Sometimes Send Packets Too Large for Part of A Given Path. Not Handling this Correctly Can make The Server unusable for some.
Correct Handling Of Oversize Packets Is by One of Two Means, As Chosen By The Sending Computer (The Server):
Permitting Packet Fragmentation - Used Mostly by OLDER Systems
Path MTU Discovery - Asking for ICMP Notification When Fragmentation Would Be Needed
By default, modern servers disable fragmentation and try to use path MTU discovery, but sometimes the system administrators block the ICMP notifications. Overall, these servers ask for ICMP notification of packets that are too large and then refuse to accept the notifications they ask for. Unable to learn that they are sending packets are too big for some paths, the servers are unable to send data to some users. to overcome this they need to accept appropriate ICMP types or allow fragmentation. We have a list of some web servers with broken Path MTU Discovery.
Path MTU Discovery
Every network link has a maximum packet size called the link's MTU (Maximum Transmission Unit). The full path from one computer to another may travel across many links with different MTUs. The smallest MTU for all the links in a path is the path MTU. If a packet starts out on a network segment with a large MTU, it may arrive at a link with a smaller MTU and be too big to fit. Most servers are on segments with large MTUs, but it is increasingly common for internet users to be connected via links with reduced MTUs, so it is becoming common for some packets to be too big. How the problem of oversize packets has been handled has evolved considerably over time. The original approach was to send only small packets corresponding to the TCP / IP default MTU (576 bytes). (to this day, a sending system needs permission from the receiving system to send larger packets, but that permisssion is given as a matter of routine.) For some packets, especially those sent by older equipment, an Oversize packet can be sent by breaking it into fragments and sending the fragments as smaller packets. The fragments can be reassembled downstream to reconstruct the original large packet, but this packet fragmentation has several problems involving both efficiency and security. Newer servers try to optimize their transmissions by discovering the path MTU and sending packets of the maximum size when there's enough data to fill them. The procedure for doing this was standardized and published as RFC 1191 in 1990, but it did not become widely deployed until years later. by mid 2002, 80% To 90% of Computers on the Internet Used path MTU Discovery. The Basic Procedure IS Simple - Send The Largest Packet You Can, And iF IT WON '
t fit through some link get back a notification saying what size will fit. The notifications arrive as ICMP (Internet Control Message Protocol) packets known as "fragmentation needed" ICMPs (ICMP type 3, subtype 4). The notifications are requested by setting the "do not fragment" (DF) bit in packets that are sent out. Some network and system administrators view all ICMPs as risky and block them all, disabling path MTU discovery, usually without even realizing it. Of the several dozen ICMP types and subtypes , some do pose some risk, but the risk is mostly mild and is of the "denial of service" nature. That is, an attacker can use them to interfere with service on and from the network. By blocking all ICMPs the administrator himself interferes with service on and from his own network. Unless he also turns off path MTU discovery on his network's servers, he makes his servers unusable by users with reduced-MTU links in their paths. Because service is affected only in relatively unusu al cases, it can be difficult to convince the administrator that a problem exists. The prevalence of such "unusual" cases is growing rapidly though. Administrators who want to block all ICMPs should disable path MTU discovery on their computers, especially on their servers. It makes no sense to ask for ICMP notifications and then refuse to accept them. In addition, doing so opens the server to a special type of distributed denial of service attack based on resource exhaustion from a large number of fully-open connections. Cisco's website HAS Summary Instructions for Disabling Path Mtu Discovery for There Systems: Windows 95/98 / ME
Windows NT 3.1 / 3.51 and 4.0
Windows 2000 / XP
Solaris
HP-UX
Elsewhere on Cisco's site they recommend using the Dr. TCP utility for Windows. Disabling path MTU on Windows systems requires modifying the Windows Registry. Microsoft's support website has information and cautions about the Registry. Path MTU discovery can be turned offUnder Linux, with the command
ECHO 1> / proc / sys / net / ipv4 / ip_no_pmtu_disc
Under freebsd, by using sysctl (8) to zero
TCP.PATH_MTU_DISCOVERY
On Cisco Routers, with the configuration command
NO IP TCP MTU-Path Discovery
Example path MTU Discovery Failure Scenario
Joe User has a DSL line. Like many DSL lines, Joe's line actually comes from a large DSL wholesaler and uses PPPoE (PPP over Ethernet) to create a logical channel between Joe and his favorite ISP. The DSL line physically connects to a small PPPoE Router with a Built-in Hub, Which Joe Uses as the basis for his home network.
The MTU on Joe's network is Ethernet's usual 1500 bytes. The MTU on his DSL line is also 1500 bytes, but PPPoE uses 8 of these bytes for an 8-byte PPPoE header, so the MTU of his PPPoE channel to his ISP is only 1492 BYTES.
A computer on Joe's Ethernet does not know about the PPPoE channel. The largest packet it can receive is a 1500-byte Ethernet packet, so when Joe uses his computer to connect to a remote server, his computer tells the server it's ok to send Packets Up to 1500 bytes. [*]
Establishing connections uses only very small packets, so Joe can connect to the server without any MTU issues, but as soon as Joe asks for enough data to fill a 1500-byte packet, the server sends a 1500-byte packet. When that packet gets to Joe's ISP, it does not fit down the PPPoE channel. The packet has the DF bit set, telling Joe's ISP to drop the packet and send the server an ICMP saying what packet size will fit. The ISP sends an ICMP saying the largest size is 1492 bytes.If the server gets that ICMP, it re-sends the first 1492 bytes as a new packet. This new packets fits down the PPPoE channel, so Joe's computer gets it and sends back an acknowledgement. The server continues sending 1492 -byte packets untric Joe Has What He Asked for. in Most Cases The Server Will Remember The Reduced Path MTU, Typical For Ten Minutes, And Use IT for Future Connections from Joe's Computer.
However, if the server does not get that ICMP, things go downhill fast. The server is expecting an acknowledgement from Joe's computer, but Joe's computer did not get the packet, so the acknowledgment never comes. After awhile, the server gives up waiting And sends the Same 1500-byte packet again. Joe's ISP Sendings Back ANOTHER ICMP. The Server Doesn't Get It Again and Tries Sending The 1500-byte Packet A Third Time, THEN A FouRTh, A Fiffh, And So ON.
Meanwhile Joe's computer can not tell this is happening and is waiting for a response from the server. Eventually, it gives up and sends the server a connection reset. It reports a network failure to Joe, who is left wondering what happened. He may Soon Discover He Can Access Nearly All Other Sites, Just Not The One HE Wanted.
If the server he's trying to access is a web server, he may get part of the website, such as getting the ads but not the main page content. This happens because the pages normally displayed for many websites are assembled from data obtained from multiple servers on a variety of networks. The networks dispensing the ads all support path MTU discovery.If Joe complains to the server operator, they may tell him the problem has to be his ISP because other users can view their server. However, Joe's ISP is not doing anything wrong, but the server operator is. PPPoE and other connections with reduced MTUs are perfectly legitimate and increasingly common. Having a server ask for ICMP noptification that it refuses to accept is what's broken behavior. Some later day, when the server site has Gotten Enough Complaints from People Like Joe to Believe Something IS WRONG, IT MAY Either Stop asking for the ICMPS or Start Accepting The Useful ones. The useful ones. The Joe Will Be Able To Access IT.
[*] What Joe's computer actually tells the remote server is that the largest payload it can send in any packet is 1460 bytes, which is the 1500-byte maximum Ethernet packet size minus 40 bytes of overhead. This maximum payload is called the MSS ( Maximum segment size).
Workarounds
There is something Joe can do in the meantime. He can reduce the MTU setting on his computer's Ethernet interface to the PPPoE MTU, 1492 bytes. Then when his computer first connects to the server, the maximum allowed packet size it gives the server will be 1492 Bytes, And The Server's Packets Will Fit Down The PPPOE CHANNEL.
In other words, if he is knowledgeable enough, Joe can overcome the server network misconfiguration by doing manually what is supposed to happen automatically.If Joe's computer is a Windows system, changing his MTU requires changing a Windows Registry setting. This is normally something that only experienced Windows-savvy users should attempt. However, misconfigured servers causing path MTU discovery problems for DSL users has become common enough that there are Windows "tuning" programs available that will do this.
If Joe runs Linux or another UNIX variant, setting the MTU is much easier, using the "ifconfig" command. However, Linux (and perhaps other UNIX variants) has something even better. He can reduce the MTU for only his default route out the PPPOE / DSL CHANNEL While Continuing to Use The Full 1500-byte MTU for Traffic On His OWN Network.
Tunnels and path MTU Discovery
Here at Netheaven, We do Not Sell PPPoe DSL Connections, But We do Sell
NetWork Tunnels That Use VPN Technologies. Some of these Tunnels Can Have Reduced MTUS, AND Our Tunnel Users Can Run Into this Problem.
However, many of our tunnel users use their tunnel to connect only a single host. Then the host running the tunnel sees the tunnel device as as network device with reduced MTU. Being aware of the lower MTU, it takes that into account when giving a Maximum Packet Size To Servers Upon Making Connections, Avoiding Any Path MTU Discovery Problems.
Overall, WHETHER OUR Tunnel Users Need Worry About The Path MTU Discovery Problem Depends Both on WHETHER THEY The Tunnel To Connect A NetWork OR A Single Host And On What Tunnel Technology THEY USE.
Among the tunnel types we support, PPTP / MPPE tunnels are usually tunnels to a single client computer, usually a Windows or Mac system. These need not worry about path MTU discovery. Our Linux users running SSL-wrapped PPP tunnels also need not worry about path MTU discovery, because these tunnels have their MTU set to 1500. [**] Users of CIPE and OpenVPN tunnels are likely to encounter occasional path MTU discovery problems if they use the computer running the tunnel as a router to connect a LAN. fortunately IT'S these Users Who Are Most Likey to Be Capable of Adjusting The Mtu of Their Lan Systems.
In Addition, Our Tunnel Users Who Use Their Tunnel of The Path Mtu Discovery Issue So Their OWN Server Doesn't WIND by Some Other Users.
[**] A tunnel having an MTU of 1500 when it's carried by packets on a link with reduced MTU is possible because PPP is level 2 even though it is encapsulated in level 3 TCP. PPP fragmenting packets is analogous to ATM shredding of packets and Does Not Violate IP Semantics. PPPoE Could Do this Too, But Apparently It Does Not. (if You Didn't Understand This Paragraph, Don't Worry About It.)