117

Is there anyway to get an error log for a failed VPN connection attempt? All I get is this notification and I have no idea where to go from there.

7 Answers 7

126

Log is written to /var/log/syslog.
Open gnome-terminal and do sudo tail -f /var/log/syslog
This will follow the file (prints to terminal new log messages).
Now try to connect to the vpn, the messages then will start showing in the terminal.
When you are done following the log just click Ctrl+c to quit tail.

One can add markers to the log by opening another terminal and doing something like that:
logger "............... Starting VPN... "

1
  • 2
    thank you. my username / password were incorrect but all I got was "connection timed out". the logs told me everything I needed to know! Mar 6, 2018 at 5:38
76

The new (systemd-)variant to get the logs is

journalctl -u NetworkManager.service
1
  • 2
    Not only it is a variant, but it includes more information. Only thanks to looking via journalctl, I was able to find an issue with Window VPN. pppd[15094]: MS-CHAP authentication failed: E=649 No dialin permission Jun 6, 2019 at 11:40
9

In Fedora and other systemd distro's that do not have /var/log/syslog, the VPN logs can be accessed with "sudo journalctl -f"

-f is for follow.

1
  • 2
    I'd suggest that that isn't really relevant as this is "askubuntu", but Ubuntu is migrating to systemd, too, and while they'll probably always have /var/log/syslog (its existence is independent of systemd, and I doubt Fedora used it before systemd), journalctl is always the correct way to view the log on systemd.
    – Auspex
    Jul 19, 2015 at 12:43
5

What kind of VPN are you trying to establish?

Is it PPTP (Microsoft proprietary) or Cisco-compatible ?

The easiest way would be for you to run pptp (for PPTP) or vpnc (for Cisco) from a console and see the possible errors interactively.

I think that vpnc is quite straight forward, you just need to type in the necessary info (gateway ip, group name/pass, user name/pass).

I haven't actually used a PPTP VPN, but some info about setting it up can be found here at cyberciti

0
1

Open the Advanced options, and tick Use a TCP connection. That fixed it for me. Ubuntu 14.04 LTS, OpenVPN.

1

Try enabling "Advanced" -> "Use Point to Point Encryption (MPPE)", this worked for me.

0

I just confirm the problem on ubuntu 14.04 LTS.

Add that if you launch the vpn manually with the following command it works at least for me:

sudo vpnc --domain "" --local-port 0 --enable-1des mypcffile

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .