I am trying to connect to a PPTP VPN server. The same config works fine in Windows but fails in Ubuntu 12.10. It must be some configuration issue.
sudo pptpsetup --create MYVPN --server xxx.xxx.xxx.xxx --username username --password passwordEverything is setup correctly. But then when I try to actually run the VPN I get this:
$ sudo pppd call MYVPN updetach
Using interface ppp1
Connect: ppp1 <--> /dev/pts/2
LCP: timeout sending Config-Requests
Connection terminated.
Modem hangupWhen I do this for more details:
tail -n 30 /var/log/syslog | grep -i ppp
Mar 18 06:33:08 tp pppd[5082]: pppd 2.4.5 started by root, uid 0
Mar 18 06:33:08 tp pppd[5082]: Using interface ppp1
Mar 18 06:33:08 tp pppd[5082]: Connect: ppp1 <--> /dev/pts/2
Mar 18 06:33:08 tp NetworkManager[988]: SCPlugin-Ifupdown: devices added (path: /sys/devices/virtual/net/ppp1, iface: ppp1)
Mar 18 06:33:08 tp NetworkManager[988]: SCPlugin-Ifupdown: device added (path: /sys/devices/virtual/net/ppp1, iface: ppp1): no ifupdown configuration found.
Mar 18 06:33:08 tp NetworkManager[988]: <warn> /sys/devices/virtual/net/ppp1: couldn't determine device driver; ignoring...
Mar 18 06:34:18 tp pppd[5082]: LCP: timeout sending Config-Requests
Mar 18 06:34:18 tp pppd[5082]: Connection terminated.
Mar 18 06:34:18 tp NetworkManager[988]: SCPlugin-Ifupdown: devices removed (path: /sys/devices/virtual/net/ppp1, iface: ppp1)
Mar 18 06:34:18 tp pppd[5082]: Modem hangup
Mar 18 06:34:18 tp pptp[5084]: anon warn[decaps_hdlc:pptp_gre.c:216]: pppd may have shutdown, see pppd log
Mar 18 06:34:18 tp pppd[5082]: Exit.Why is it not connecting? It works fine from Windows, so it must be something with Ubuntu 12.10 settings...
EDIT:
sudo pppd call MYVPN debug dump logfd 2 updetachIs there any information about how to utilize this information to see what might have gone wrong?
pppd options in effect:
debug # (from command line)
updetach # (from command line)
logfd 2 # (from command line)
dump # (from command line)
noauth # (from /etc/ppp/peers/MYVPN)
name username # (from /etc/ppp/peers/MYVPN)
remotename MYVPN # (from /etc/ppp/peers/MYVPN) # (from /etc/ppp/peers/MYVPN)
pty pptp xxx.xxx.xxx.xxx --nolaunchpppd # (from /etc/ppp/peers/MYVPN)
crtscts # (from /etc/ppp/options) # (from /etc/ppp/options)
asyncmap 0 # (from /etc/ppp/options)
lcp-echo-failure 4 # (from /etc/ppp/options)
lcp-echo-interval 30 # (from /etc/ppp/options)
hide-password # (from /etc/ppp/options)
ipparam MYVPN # (from /etc/ppp/peers/MYVPN)
nobsdcomp # (from /etc/ppp/peers/MYVPN)
nodeflate # (from /etc/ppp/peers/MYVPN)
noipx # (from /etc/ppp/options)
using channel 27
Using interface ppp1
Connect: ppp1 <--> /dev/pts/2
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x0 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <callback CBCP> <mrru 1614> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]> < 17 04 01 00>]
sent [LCP ConfRej id=0x0 <callback CBCP> <mrru 1614> < 17 04 01 00>]
rcvd [LCP ConfReq id=0x1 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <callback CBCP> <mrru 1614> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]> < 17 04 01 00>]
sent [LCP ConfRej id=0x1 <callback CBCP> <mrru 1614> < 17 04 01 00>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x4 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <callback CBCP> <mrru 1614> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]> < 17 04 01 00>]
sent [LCP ConfRej id=0x4 <callback CBCP> <mrru 1614> < 17 04 01 00>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x6 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
sent [LCP ConfAck id=0x6 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x9 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
sent [LCP ConfAck id=0x9 <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x4e812c17> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0xc <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
sent [LCP ConfAck id=0xc <mru 1400> <auth chap MD5> <magic 0x27f847d4> <pcomp> <accomp> <endpoint [local:f8.7d.55.9e.60.00.42.53.ac.37.23.b6.c9.f4.6d.2f.00.00.00.00]>]
LCP: timeout sending Config-Requests
Connection terminated.
Modem hangup
Waiting for 1 child processes... script pptp xxx.xxx.xx.xxx --nolaunchpppd, pid 6815
Script pptp xxx.xxx.xx.xxx --nolaunchpppd finished (pid 6815), status = 0x0 3 7 Answers
I experienced exactly the same issue on my VPN, which started after installing Utopic HWE kernel 3.16.0 on Ubuntu 14.04 LTS.
After researching I found the root cause of the issue:
Using interface ppp0
Connect: ppp0 <--> /dev/pts/4
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <auth chap MS-v2> <magic 0x792e9abe> <pcomp> <accomp>]
LCP: timeout sending Config-Requests
Connection terminated.
Modem hangupThe root cause was that 2 required netfilter kernel modules are not loaded during boot:
nf_conntrack_pptp
nf_conntrack_proto_greSolution: load the nf_conntrack_pptp module, the latter is its dependency and will be loaded automatically.
sudo modprobe nf_conntrack_pptpReferences:
2I have googled 'LCP: timeout sending Config-Requests' for a while, and can't find a solution. Some posts said it is related with router setting, but I have my MAC and android phone connected without problem, so it is not my router's problem.
After poking ppp setting around, I find solution working for me. Edit /etc/ppp/options, enable option silent, then problem solved.
# With this option, pppd will not transmit LCP packets to initiate a # connection until a valid LCP packet is received from the peer (as for # the "passive" option with old versions of pppd). silentI use Ubuntu 12.04, and setup VPN from GUI
2For the majority of distributions you must load the nf_conntrack_pptp and nf_conntrack_proto_gre kernel modules for certain PPTP/VPN servers. This can be done with:
$ sudo modprobe nf_conntrack_pptp(nf_conntrack_proto_gre is loaded automatically as a dependency of nf_conntrack_pptp)
Mar 18 06:34:18 tp pppd[5082]: LCP: timeout sending Config-Requests
This may be an issue with GRE (ip 47) protocol. Check this page:
Also try to connect to 1723 on pptp server:
telnet "server-ip-or-host" 1723If this port is not blocked I recommend to check firewall settings on computer and router(some routers have pptp/gre passthrough option)
1Did not helped any other solution but i found out another solution. Had the same error that is trying to connect but is timing out.
Debug
I did $ tail -f /var/log/syslog and saw a around 10 lines of these messages:
Apr 21 22:20:37 user-pc kernel: [ 3008.652602] [UFW BLOCK] IN=wlxxxxxxxxxxxx OUT= MAC=00:a0:a0:00:00:00:a0:a0:a0:00:00:00:00:00 SRC=111.222.333.444 DST=111.222.333.444 LEN=54 TOS=0x00 PREC=0x00 TTL=59 ID=43069 PROTO=47
And after that a failure message
Apr 21 22:20:38 tp pppd[5082]: LCP: timeout sending Config-Requests
Fix
Since I saw [UFW BLOCK] I found out that UFW (firewall) is blocking incoming traffic. Then added rule to UFW to allow the traffic from my VPN client with this command:
$ sudo ufw allow proto gre from [ip_of_pptp_server]
$ sudo service ufw restartthen I tried to reconnect PPTP VPN and it worked.
1SOLUTION : We also had the same problem. The issue is because of the mismatch of pptp client version & ubuntu version. Instead of apt-get we manually need to download & compile the source.
Download the latest version of pptp client source from official website
cd /pptp-1.9.0
make
cp pptp /usr/sbinAfter these steps, VPN is connecting.
1We were getting this error (The VPN connection 'MY-VPN' failed because the VPN service stopped unexpectedly) because we allowed ufw. like
sudo ufw allow 1433Once we disabled ufw using the following command, the VPN connected successfully again.
sudo ufw disable