Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a .ovpn file with my VPN config - it works fine when I do

sudo openvpn --config ~jrg/Documents/vpn-config.ovpn 

in the terminal, but I'd like to use Network Manager. How can I do this?

share|improve this question

3 Answers 3

up vote 14 down vote accepted

First, install the OpenVPN Network Manager plugin:

sudo apt-get install network-manager-openvpn-gnome

Open Network Manager, select the VPN tab, then click "Import". Navigate to your .ovpn file (~jrg/Documents/vpn-config.ovpn). If it doesn't automatically find your certificates/keys (the paths of which are found in the .ovpn file), you can select them here, or make any other small changes.

openvpn dialog

One other thing that may save you some headache down the road is to click IPv4 Settings, then change the method to "Automatic (VPN) Addresses Only". When kept at the default, this will cause ALL internet traffic to go over the VPN, regardless of your .ovpn settings. Here you can also set the DNS server and search domains to use while connected.

openvpn dialog

share|improve this answer
1  
It doesn't show the certificates and such when I click "Import". –  jrg Sep 13 '12 at 22:35
    
I updated my answer to be a little more thorough. If the options just aren't showing up, than you either have a misconfigured .ovpn and aren't actually using them, or you need to change the "Type" drop-down box. –  reverendj1 Sep 14 '12 at 14:34
    
Were you able to get it to work? –  reverendj1 Sep 19 '12 at 14:14
    
there is a bug in network manager for ovpn files. see bugs.launchpad.net/ubuntu/+source/network-manager-openvpn/+bug/… –  lenzai Oct 1 '12 at 10:05
3  
there's no "Import..." button in my case (using debian jessie...) :( –  knocte Jun 7 '13 at 13:33

When you aren't given an user certificate, you must select the 'Password' type in the authentication drop down. Then in advanced, in 'TLS Authentication' add the TLS .key file and set the direction accordingly (1 or 0, that should be set in the .ovpn file).

share|improve this answer

It's late to answer, but I found a solution...

  1. Create a folder in your home directory called .OpenVPN (with the dot in front of it so it is hidden) then open that folder and create one called FrootVPN (no dot needed). This makes management of different VPN providers easier.
  2. Copy/Paste froot.ovpn to the /home/YOU/.OpenVPN/FrootVPN folder.
  3. Open the froot.ovpn file with a text editor.
  4. Copy everything between the ca /ca tags.
  5. Paste the contents to a new file and save it as ca.crt within the /home/YOU/.OpenVPN/FrootVPN folder.
  6. Click on the Network Manager icon and go to VPN CONNECTIONS > CONFIGURE VPN...
  7. Click on ADD and select OpenVPN. Click CREATE.
  8. Call it FrootVPN and use se-openvpn.frootvpn.com for the Gateway. Type will be PASSWORD. Enter your FrootVPN username and password. On CA Certificate, click the folder icon and browse to the ca.crt file you created.
  9. Change the Method on both the IPv4 and IPv6 tabs to Automatic (VPN) addresses only.
  10. Click SAVE then click CLOSE.

Now you can connect to FrootVPN by clicking on the Network Manager icon and going to VPN Connections > FrootVPN.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.