Every time I log in to my VPN server via ppp, I must change the MTU to 1492 using the following method:

ifconfig ppp0 mtu 1492

If I do not do this, then random websites will simply hang up and never load. I must do this every single time I log into the server. Is there anyway to set this permanently?

I am fairly new to Linux (at least settings like this, I just found this command after doing a Google search), so please be as specific as possible!

  • 1
    How did you set up this "VPN"? Why are you using PPP at all? – Michael Hampton Nov 25 '13 at 19:52
  • @MichaelHampton As I said, I am fairly new to Linux. It seems that PPP was the most common way of doing it and the easiest. Since it was common, I could easily find support and tutorials. So I choose that method. – alexander7567 Nov 25 '13 at 19:54
  • It might have been common a decade ago, but these days anyone who cares in the least about the actual security of their VPN stays away from PPTP. It's been known to be insecure for years now. – Michael Hampton Nov 25 '13 at 19:56
  • PPTP is not insecure (some implementations of the prehistoric MSCHAP mechanism were broken a million years ago, using TLS based key exchange is relatively secure) - but that's beside the point - we don't know what vpn technology alexander75767 uses - and in the absence of that information this question can't be properly answered. – symcbean Nov 25 '13 at 22:43

Try add the following to the /etc/sysctl.conf

net.ipv4.ip_no_pmtu_disc = 1

and then invoke sysctl -p

i hope this works for you

| improve this answer | |

Assuming CentOS (I use 7.7) and NetworkManager this is what I do in such case:

nmcli conn mod <connection name> ppp.mtu 1492

You have to restart interface to apply the change:

nmcli conn down <connection name>; nmcli conn up <connection name>

Have a look at man nm-settings for all connection settings available in NetworkManager.

| improve this answer | |

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.