The openvpn of my company is pushing about 250 routes. I can connect by the command line interface of openvpn by using max-routes 300 in the clients config file. By importing this file into nm, this setting is ignored and the connection fails due to too many routes. There is already a bug report upstream, nevertheless, I'm searching for a workaround for the few colleagues running linux. All of them run ubuntu, therefore a ubuntu-specific workaround would help.

To give some starting point, what I searched for and google was not answering is the possibility of a global configuration of openvpn options to set max-routes or the ability to give nm additional options that don't show up in the gui.

Solved: The upstream problem was solved about 1 year ago. Unfortunately too late for me since I left the company, and there's no other linux machine left, they are purely running Windows and Apple now.

  • 1
    I'm facing this problem too, for a workaround, do not use network-manager-openvpn. – favadi Mar 22 '14 at 2:41
  • @favadi: That's what I actually do, I use the openvpn CLI. Nevertheless, I still hope for a possibility to overwrite the max-routes setting somewhere in the nm to be able to use the GUI. The GUI has several benefits, e. g. it is possible to configure if the internet traffic is routet over vpn or not, which I have to do manually with the CLI (of course I could write a script, but at least I have to entirely understand the complex routing that is introduced by the openvpn connection, more than 250 routes in total, in the GUI it's just one click), and it makes my desktop less cluttered. – Chris Mar 23 '14 at 10:16
  • @favadi: ... (not enough space in one comment) Additionally, several colleagues just don't want to use the CLI (for whatever reason). – Chris Mar 23 '14 at 10:17

When you open the connection settings, click on Advanced. At the end of the General tab, should be the setting for Specify max routes.

Network Manager 1.2.6 and network-manager-openvpn 1.2.6-2ubuntu1 here.

  • The necessary functionality seems to have been added during the last 3 years. Unfortunately I cannot test since I have no access to this network any more. – Chris Jul 13 '17 at 11:21

I'm facing with such problem too. Openvpn can be started with option --max-routes xxx, where xxx - number of routes. So, I rename file /usr/sbin/openvpn to /usr/sbin/openvpnm (modified). Then create new file /usr/sbin/openvpn with the following:

/usr/sbin/openvpnm --max-routes 500 "$@"

Where 500 is number of the routes.

Make this file executable:

chmod +x /usr/sbin/openvpn

Now Network manager works with fine.

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.