Ubuntu – L2tp IPSEC PSK VPN client on (x)ubuntu 16.04

vpn

I am looking for a solution in order to connect to a vpn l2tp ipsec server from my Xubuntu 16.04 pc. I used to have Xubuntu 14.04 and I could connect without any problems following these tutorials:
https://www.elastichosts.com/blog/linux-l2tpipsec-vpn-client/
https://soeasytomakeitwork.wordpress.com/2014/05/02/set-up-a-l2tpipsec-vpn-connection-on-ubuntu-desktop/

Unfortunately Openswan package seems to be old and not available anymore.
I've tried everything including everything from this page:
How to connect to L2TP over IPSec VPN?
but nothing woks. After some dependency packages failure with libctemplate2 I succeeded to install ipsec service but i got the following error when I'm trying to ipsec auto –up:
whack: Pluto is not running (no "/var/run/pluto/pluto.ctl")

systemctl restart ipsec.service does not show any error but when I'm checking with status I got this:

root@Vapor:/usr/lib/ipsec# systemctl status ipsec.service
● ipsec.service - LSB: Start Openswan IPsec at boot time
   Loaded: loaded (/etc/init.d/ipsec; bad; vendor preset: enabled)
   Active: active (exited) since Lu 2016-06-20 21:23:33 EEST; 31s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 14634 ExecStop=/etc/init.d/ipsec stop (code=exited, status=0/SUCCESS)
  Process: 14654 ExecStart=/etc/init.d/ipsec start (code=exited, status=0/SUCCESS)

iun 20 21:23:33 Vapor ipsec__plutorun[14776]:         [--nat_traversal] [--keep_alive <delay_sec>] \
iun 20 21:23:33 Vapor ipsec__plutorun[14776]:         [--force_keepalive] [--disable_port_floating] \
iun 20 21:23:33 Vapor ipsec__plutorun[14776]:         [--virtual_private <network_list>]
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: Openswan 2.6.38
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: pluto unexpectedly said `exit'
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: pluto unexpectedly said `1'
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: connect(pluto_ctl) failed: No such file or directory
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: whack: Pluto is not running (no "/var/run/pluto/pluto.ctl")
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: pluto died without exit status!?!
iun 20 21:23:33 Vapor ipsec__plutorun[14776]: internal failure in pluto scripts, impossible to carry on
root@Vapor:/usr/lib/ipsec# 

I've never thought that this can be so difficult. I've read that the ipsec Openswan was replaced by Strongswan but I don't understand what I have to do in order to connect to a L2tp IPSEC server using a preshared key. The server I am talking about is hardware built in.

This start to be extremely annoying and I'm thinking to go back to some previous versions of ubuntu.

This shouldn't be happening in an LTS version.

Any help will be very much appreciated. Even a fresh idea, different software, whatever, doesn't matter what, I want to make it work!!!

Best Answer

You can use

sudo add-apt-repository ppa:nm-l2tp/network-manager-l2tp  
sudo apt-get update  
sudo apt-get install network-manager-l2tp
sudo apt-get install network-manager-l2tp-gnome

To install the network manager l2tp that supports L2TP for ubuntu 16.04

Walkthrough for building from source: http://blog.z-proj.com/enabling-l2tp-over-ipsec-on-ubuntu-16-04/

Related Question