cancel
Showing results for 
Search instead for 
Did you mean: 

How to set up my MTU

MickKi
Grafter
Posts: 543
Registered: ‎30-09-2007

How to set up my MTU

Hi All,
Metronet-ADSL used to have a guide on setting up the MTU and I recall a value of 1480 or something like that as the 'optimum' recommended for most types of connections.  That was back in the pre-ADSL Max days.  I think that the article also said 1500 is better for large file downloads over ftp.
I saw the video on plusnet for setting up MTU, which however is based on a Java applet - not good for my set up (I do not have Java installed and would rather not install it just for this).  The old Metronet webpages gave an example of using ping with progressively increased packet sizes until fragmentation started occuring.
I have recently changed my hardware and I saw this on my router:
ppp 1 is UP
  Configuration:
    Keep-alive is set (10 sec.)
    No multilink
      MTU = 1500
    Peer authenticates with CHAP
    IP is configured
      IP address negotiated
  Link thru eth 0/1 is UP; LCP state is OPENED, negotiated MTU is 1500
    Receive: bytes=5627036, pkts=5752, errors=0
    Transmit: bytes=883091, pkts=5356, errors=0
    5 minute input rate 2192 bits/sec, 1 packets/sec
    5 minute output rate 848 bits/sec, 1 packets/sec

However, further down I saw this:
    IP is UP, IPCP state is OPENED
      Negotiated Address=XXX.XXX.XXX.XXX Mask=255.255.255.255
      Peer address=195.166.128.64
      DNS: Primary=212.159.13.50, Secondary=212.159.13.49
      IP MTU=1492, Bandwidth=100000 Kbps
    LLDPCP State is STOPPED

All PCs on my LAN have MTU set at 1500 (I think this is the default) and so has the ADSL modem.  Does the "IP MTU=1492" above mean that the packets sent out from the LAN are going to be fragmented?  Shall I reduce the PCs and modem MTU so that it is also 1492?
Also, are there any tests I could run from a Linux box to determine the optimum MTU?
--
Regards,
Mick
6 REPLIES 6
samuria
Grafter
Posts: 1,581
Thanks: 3
Registered: ‎13-04-2007

Re: How to set up my MTU

the page you seek is
http://help.expedient.com/broadband/mtu.shtml
and the ping test page is
http://help.expedient.com/broadband/mtu_ping_test.shtml
If you dont know what you are doing its best left alone as you can make things ten times worse.
There are 2 mtu setting to consider your pc and the router. The router talks directly to the internet so has one setting and the pc talks via the rooter.
Most routers are happy at 1500 but some may do a little lower say 1497.
VileReynard
Hero
Posts: 12,616
Thanks: 582
Fixes: 20
Registered: ‎01-09-2007

Re: How to set up my MTU

It's worth saying that if you have either a Windows Vista (but not XP etc) or a Linux OS then they will try to choose optimum network parameters for you, including MTU size.

"In The Beginning Was The Word, And The Word Was Aardvark."

James
Grafter
Posts: 21,036
Thanks: 5
Registered: ‎04-04-2007

Re: How to set up my MTU

I noticed a considerable change when changing my router MTU from 1500 to 1430.
To the tune of about 3Mbps.
ed
Grafter
Posts: 191
Registered: ‎15-08-2007

Re: How to set up my MTU

look up TCP Optimizer on Google Smiley
MickKi
Grafter
Posts: 543
Registered: ‎30-09-2007

Re: How to set up my MTU

Thank you all for your advice and links!  Smiley
Quote from: Jameseh
I noticed a considerable change when changing my router MTU from 1500 to 1430.
To the tune of about 3Mbps.
I am not at home to try my ADSL-Max right now, but at work where we have a fixed speed 1152/288 kbps BT ADSL line I could not see a discernible difference between different settings.  One thing was sure out of my MTU ping tests:  the MTU value set at the PC determines the MTU Ping test result (i.e. the MTU test value, above which fragmentation occurs).  Add to that 28 for the IP header and you're back at the MTU value I had set at the NIC.
$ ping -c 3 -v -M do -s 1472 212.58.251.201
PING 212.58.251.201 (212.58.251.201) 1472(1500) bytes of data.
1480 bytes from 212.58.251.201: icmp_seq=1 ttl=241 time=78.8 ms
1480 bytes from 212.58.251.201: icmp_seq=2 ttl=241 time=78.6 ms
1480 bytes from 212.58.251.201: icmp_seq=3 ttl=241 time=77.5 ms
--- 212.58.251.201 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 77.548/78.337/78.863/0.653 ms
In this case I add 28 and arrive at the value of 1500, which is exactly what I set the interface card at.  I tried values of 1500, 1490, 1480 and 1430 at the PC and router and could not see much of a difference.  If anything I would say that an MTU of 1500 gave the best result, not in terms of ping round trip time but as shown by www.speedtest.net).
Some Qs:

  • Should I expect something different when I try this test at the ADSL-Max line?

  • Is the MTU ping test merely reflecting what the PC MTU has been set at?

  • Is there another test (that doesn't involve a Java applet) I could try?
MickKi
Grafter
Posts: 543
Registered: ‎30-09-2007

Re: How to set up my MTU

I did some more tests and research and can report the following:
1.  Path MTU discovery on a server will test what is the maximum packet that a client connected to that server will support and then send packets of that size back to the client.  If any connection on the way (firewall(s), etc) are blocking ICMP packets, or the server has been configured not to accept ICMP (type 3, subtype 4) packets, PMTU will not work.  In that case certain connections will be troubled with high fragmentation and therefore slower than possible speeds and high latency.
2.  To overcome the above it may pay to set the MTU manually (rather than rely on the PMTU mechanism).  Given that BT based Broadband uses ATM encapsulation (PPPoA) and this requires 42 bytes, we are left with 1500-42=1458.  Therefore the MTU for BT based PPPoA Broadband is 1458 (while for PPPoE is 1492 and for cable/LAN I believe it is 1500).  Any packets above that size will incur fragmentation.  Metronet ADSL support also advised that this is what BT recommends for their network and it makes sense.
3.  Using something like www.speedtest.net to measure your connection speed is probably not very accurate.  This is because the download is not particularly large.  Try instead to download an iso package (e.g. for Debian, Ubuntu, SUSE, etc. or your local favourite software supplier) from your nearest mirror.  After a minute or so the download would have stabilised and then you'll know what your speed under load is (please don't abuse the mirrors).
4.  Don't forget to set the MTU for all computers on your network and all the network devices; e.g. router *and* modem.  Using the MTU discovery ping test I found that my modem was set to a different figure than my router.  Roll_eyes
5.  None of the above is going to cure pipe contention and ToS throttling.  In busy times, or if you have exceeded your monthly bandwidth allowance (for those of us who are on PAYG service) expect speeds to be lower.  Unless you can afford dedicated fiber to the desktop, you ain't gonna get 8mbps any time soon.  Tongue
Hope this helps others to solve their MTU problems.
--
Regards,
Mick