apt-get install pptp-linux
echo "yourvpnusername * yourpasspass *" >> /etc/ppp/chap-secrets
vi /etc/ppp/peers/provpnaccounts.com
enter (ignore the lines):
============
pty "pptp server.provpnaccounts.com --nolaunchpppd"
name testuser
#remotename PPTP
require-mppe-128
file /etc/ppp/options.pptp
============
#add this to /etc/ppp/ip-up
Where eth0 is your NIC and ppp0 is the name of your VPN connection
route del default eth0
route add default dev ppp0
Connect:
pppd call provpnaccounts.com
Disconnect:
killall pppd
Customize it
What I do is add the following to /etc/rc.local
pppd call provpnaccounts.com
Make it so the VPN reconnects by itself:
vi /etc/ppp/options
persist
debian, linux, ubuntu, mint, pptp, terminal, bash, shell, apt, install, echo, quot, yourvpnusername, yourpasspass, etc, ppp, chap, vi, peers, provpnaccounts, pty, server, nolaunchpppd, testuser, remotename, mppe, ip, eth, nic, vpn, default, dev, pppd, disconnect, killall, customize, rc, reconnects, persist,