Setup pptp service on ubuntu

1.Istall PPTPd

sudo apt-get install pptpd

sudo nano /etc/pptpd.conf

delete # of:localip remoteip,

2. Add Acount &change DNS

sudo nano /etc/ppp/chap-secrets

add :username  pptpd  "password"  *

sudo nano /etc/ppp/pptpd-options

delete # of ms-dns,change into,,

sudo nano /etc/sysctl.conf

delete # of  net.ipv4.ip_forward=1

sudo sysctl -p

3.Install iptables

sudo apt-get install iptables
sudo iptables -t nat -A POSTROUTING -s -o eth0 -j MASQUERADE

4.restart service

sudo service pptpd restart

5.Change rules

/sbin/iptables -I FORWARD -p tcp --syn -i ppp+ -j TCPMSS --set-mss 1356

Leave a Reply

Your email address will not be published. Required fields are marked *