• Home
  • InControl User Guide
  • Peplink Router API Documentation
  • Peplink News
  • Home
  • InControl User Guide
  • Peplink Router API Documentation
  • Peplink News
home/Knowledge Base/Networking/How to determine the optimal MTU and MSS size

How to determine the optimal MTU and MSS size

989 views 0 14/11/2020 30/11/2020 Martin Langmaid

This content is from the original forum article (here).

Setting the correct MTU size can make a difference in optimizing your network speeds.

The MTU size, or Maximum Transmission Unit Size, is the largest physical packet size, measured in bytes, that a network can transmit.
Any messages larger than the MTU are divided into smaller packets before being sent.

The default setting of the MTU size on Peplink routers is 1440 to accommodate for the different quality of ISP connections from around the world.

The best value for MTU is that value just before your packets get fragmented.

Using the PING command to determine MTU size

You can determine the optimal MTU size by using PING at a command prompt.
Open a command prompt and type (start by using a value of 1472 which is equivalent to MTU size 1500):

Ping www.peplink.com -f -l 1472

Then Press Enter.

If you see the message “Packet needs to be fragmented but DF set.” , you need to lower the packet size.

Then try a lower packet size (for example 1412) until you get a successful ping response instead of the “Packet needs to be fragmented but DF set.” message.
Keep changing the packet size until you have found the highest packet size that can be sent in your network without being fragmented.

Add 28 more to this (since you specified ping packet size, not including the IP/ICMP header of 28 bytes) And this is your Maximum MTU.

In my case the maximum packet size is 1412 + 28 = 1440.

Adjusting the MTU size on a Peplink router

In the web interface of your Peplink router open the WAN connection details to adjust your MTU size.
If your optimum MTU size is not 1440, select Custom Value and type in your optimum MTU size.

If you would like to do the same in OS X use the following command instead in a text editor:

ping -D -s 1472 www.peplink.com

What about the MSS size?

Additionally, there is a field to specify the MSS size, or Maximum Segment Size of the WAN connection.
This value will be announced to remote TCP servers for maximum data that it can receive during the establishment of TCP connections.
When Auto is selected, MSS is dependent on the MTU value.
Some Internet servers are unable to listen to MTU setting if ICMP is filtered by firewall between the connections, in which case it could be necessary to configure the MSS settings.

image

The maximum segment size (MSS) is a parameter of the options field of the TCP header that specifies the largest amount of data, specified in bytes, that a computer or communications device can receive in a single TCP segment. It does not count the TCP header or the IP header (unlike, for example, the MTU for IP datagrams).

Normally, MSS is equal to MTU minus 40.

You are recommended to reduce the MSS only if changing the MTU value cannot effectively inform some remote servers to size down data size.

Was this helpful?

Yes  No
Related Articles
  • Port Forwarding to a LAN Device From A Peplink Router
  • Can wi-fi Users Be Prevented from Logging into Peplink’s Web Admin Interface?
  • Port Forwarding to a LAN Device From A Fusionhub
  • Controlling Bandwidth to Users with QoS and User Groups
  • Firewall Rules & Port Mapping
  • LAN Port VLAN Mapping
Leave A Comment Cancel reply

Popular Articles
  • Obtaining IP Address
  • Firewall Rules & Port Mapping
  • How to connect using WiFi-WAN in new locations
  • What’s the difference between ‘Access’ and ‘Trunk’ Ports?
  • Port Forwarding to a LAN Device From A Peplink Router
KB Categories
  • Installation & Setup
  • InControl
  • Cellular
  • WiFI
  • Switches
  • Networking
  • General
Popular Articles
  • Obtaining IP Address
  • Firewall Rules & Port Mapping
  • How to connect using WiFi-WAN in new locations
  • What’s the difference between ‘Access’ and ‘Trunk’ Ports?
  • Port Forwarding to a LAN Device From A Peplink Router
KB Categories
  • Installation & Setup
  • InControl
  • Cellular
  • WiFI
  • Switches
  • Networking
  • General
Have an idea for an article?

    About This Site
    ninja.knowhow is an independent training and documentation rescource for Peplink products and technologes. This site is owned and operated by Slingshot6.
    Resources
    • Support Forum
    • Design Lab
    • Peplink on Youtube
    Have a Request?
    Are you looking to answer a specific question? Do you want to learn about something not covered here?
    Get In Touch
    • Privacy Policy
    • Terms of Use
    • Copyright 2020 Slingshot6 Ltd. All Rights Reserved.