红联Linux门户
Linux帮助

Linux下配置PPTP客户端

发布时间:2014-11-25 22:09:30来源:linux网站作者:dead-horse

安装自带ppp / libpcap
安装pptp http://pptpclient.sourceforge.net/

命令行配置:
pptpsetup --create vpntovps --server vpn.zhangjianfeng.com --username jeffrey --password 123456 --encrypt

cat /etc/ppp/peers/vpntovps
pty "pptp vpn.zhangjianfeng.com --nolaunchpppd"
lock
noauth
nobsdcomp
nodeflate
name jeffrey
remotename vpntovps
ipparam vpntovps
require-mppe-128

cat /etc/ppp/chap-secrets
# added by pptpsetup for vpntovps
jeffrey vpntovps "123456" *

cp /usr/share/doc/ppp-2.4.4/scripts/poff /usr/sbin/
cp /usr/share/doc/ppp-2.4.4/scripts/pon /usr/sbin/
chmod +x /usr/sbin/pon /usr/sbin/poff
pon vpntovps #连接
poff #断开VPN
route add -net 0.0.0.0 dev ppp0 #添加路由