This worked for me. Use at your own risk. YMMV. Edit: See post #4 below for an important update to this post ...
I've bleated previously here and on Launchpad about how PPTP VPN worked perfectly under Hardy and was broken under Intrepid and Jaunty. For me, this was a "deal-breaker" because I need PPTP VPN access. I have not upgraded my desktop Hardy machine for this reason. I did upgrade my laptop to Intrepid and now to Jaunty and got around the problem by using PPTP VPN in a Xubuntu Hardy VirtualBox.
I've spent the evening looking at this again and I've managed to get PPTP VPN working on my Jaunty laptop. I'm not a PPTP or VPN expert by any means.
I used this post as starting point, so thanks to kryptoz. The problem as I can see it is that Network Manager 0.7 (Intrepid and Jaunty) and the associated PPTP plugin are broken. Under Hardy (Network Manager 0.6.6) everything works. There are many posts detailing the myriad problems with Network Manager 0.7. However, using the Network Manager applet is simply a front-end to calling PPTP and PPPD which actually make the connection (I think).
My solution does not involve the Network Manager applet at all. The connection is established by calling PPPD. The pptp-linux and ppp (for pppd) package must be installed and the pptpd package as well (I think).
1. Add the following to /etc/ppp/chap-secrets:
Code:
Username PPTP Password *
2. Create /etc/ppp/peers/vpn1. The 'peers' folder may be owned by group 'dip' so get around that by adding yourself to the group (I have no idea if this is a good solution, but it worked). Add the following to the vpn1 file:
Code:
pty "pptp remote.gateway.address.here --nolaunchpppd"
name Username
remotename PPTP
require-mppe-128
file /etc/ppp/options.pptp
ipparam vpn1
3. Edit the options.pptp file as required. I commented out the 'refuse-chap' and 'refuse-mschap-v2' lines.
4. Establish the VPN connection with:
Code:
sudo pppd call vpn1
or
5. Drop the connection when you're done with:
That establishes a VPN connection but I could not get any traffic through it. Therefore, create '/etc/ppp/ip-up.d/route-traffic' as follows. I don't know why the file needs to have that name or be located in that folder, because it does not appear to be executed automatically. Thanks to this site for this information:
Code:
#!/bin/bash
NET="10.0.0.0/8"
IFACE="ppp0"
route add -net ${NET} dev ${IFACE}
Make the file executable.
Replace the "10.0...." address with the range of addresses you need to access on your remote machine. For me, this was the same range as that which I originally included when setting the VPN up in Hardy. It may look like "10.2.0.0/16" for example. The values don't have to be in the "10" range (mine were not).
So, to get the VPN up in Jaunty, I did the following (in /etc/ppp/ip-up.d):
Code:
sudo pon vpn1
sudo ./route-traffic
Edit: See post #4 below for an important update to this post ...
Bookmarks