Skip to content

Instantly share code, notes, and snippets.

@andresbott
Created January 19, 2016 01:49
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save andresbott/b5586fadc36ba46fdac1 to your computer and use it in GitHub Desktop.
Save andresbott/b5586fadc36ba46fdac1 to your computer and use it in GitHub Desktop.
Solve mppe_compress[0]: osize too small! (have: 1408 need: 1412)
taken from: http://danielsokolowski.blogspot.com.es/2013_04_01_archive.html
This due to the way MPPE Microsoft point-to-point Encryption encodes data which results in the packet size being bigger then what was agreed in the VPN handshake - is my guess. There is a reported bug from 2005 which sadly hast not yet been addressed.
Fixing the issue by increasing the MTU
You can't fix this issue by modifying the MTU/MRU settings in '/etc/ppp/options' directly, you have to adjust the MTU after the PPP connection is up and this can be accomplished by adding a custom 'ip-up' script.
Below is my workaround script, place it into file '/etc/ppp/ip-up.d/mppefixmtu' and ensure that it is executable ('chmod +x mppefixmtu'):
#!/bin/sh
CURRENT_MTU="`ifconfig $1 | grep -Po '(?<=MTU:)([0-9]+)'`"
FIXED_MTU="`expr $CURRENT_MTU + 4`"
ifconfig $1 mtu $FIXED_MTU
echo "Increased MTU for $1 to $FIXED_MTU (from $CURRENT_MTU) to fix MPPE Microsoft Point-to-Point bug #330973"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment