Centos 6 pptp server on OpenVZ


yum list installed | grep ppt
ppp.x86_64 2.4.5-10.el6 @base
pptpd.x86_64 1.4.0-3.el6 @epel

cat /etc/pptpd.conf
option /etc/ppp/options.pptpd
logwtmp
connections 156
localip your_vpn_server_IP_address
remoteip 192.168.0.101-200

cat /etc/ppp/options.pptpd
name pptpd
refuse-pap
refuse-chap
refuse-mschap
require-mschap-v2
require-mppe-128
ms-dns 8.8.8.8
ms-dns 8.8.4.4
proxyarp
lock
nobsdcomp
novj
novjccomp
nologfd

cat /etc/ppp/chap-secrets
vpn_username * your_client_password *

/etc/init.d/pptpd start

iptables:

-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT
-A INPUT -i ppp+ -j ACCEPT
-A INPUT -p tcp -m tcp --dport 1723 -j ACCEPT
-A INPUT -p gre -j ACCEPT
-A OUTPUT -p gre -j ACCEPT

-P PREROUTING ACCEPT
-P POSTROUTING ACCEPT
-P OUTPUT ACCEPT
-A POSTROUTING -j MASQUERADE

echo 1 > /proc/sys/net/ipv4/conf/venet0/proxy_arp
vi /etc/ppp/ip-up.local
ifconfig ppp0 mtu 1468

MPPE should be enabled on client side.


Jan 16 07:27:17 cloudlix pptpd[2616]: CTRL: Starting call (launching pppd, opening GRE)
Jan 16 07:27:17 cloudlix pppd[2617]: Plugin /usr/lib64/pptpd/pptpd-logwtmp.so loaded.
Jan 16 07:27:17 cloudlix pppd[2617]: pppd 2.4.5 started by root, uid 0
Jan 16 07:27:17 cloudlix pppd[2617]: Using interface ppp0
Jan 16 07:27:17 cloudlix pppd[2617]: Connect: ppp0 <--> /dev/pts/1
Jan 16 07:27:17 cloudlix pppd[2617]: peer from calling number XX.80.253.XX authorized
Jan 16 07:27:17 cloudlix pppd[2617]: MPPE 128-bit stateless compression enabled
Jan 16 07:27:17 cloudlix pppd[2617]: Cannot determine ethernet address for proxy ARP
Jan 16 07:27:17 cloudlix pppd[2617]: local IP address 5.199.XX.XX
Jan 16 07:27:17 cloudlix pppd[2617]: remote IP address 192.168.0.101
Jan 16 07:28:15 cloudlix pppd[2617]: Modem hangup
Jan 16 07:28:15 cloudlix pppd[2617]: Connect time 1.0 minutes.
Jan 16 07:28:15 cloudlix pppd[2617]: Sent 2200951 bytes, received 163549 bytes.
Jan 16 07:28:15 cloudlix pppd[2617]: MPPE disabled
Jan 16 07:28:15 cloudlix pppd[2617]: Connection terminated.
Jan 16 07:28:15 cloudlix pppd[2617]: Exit.
Jan 16 07:28:15 cloudlix pptpd[2616]: CTRL: Client XX.80.253.XX control connection finished

Views All Time
Views All Time
254
Views Today
Views Today
1

Leave a Reply

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