Sunday, May 29, 2011

centos5.5 安装pptpd vpn


公司IDC机房十多台机器,现需要在监控服务器上面安装vpn,以后都经过这台vpn服务器来对其他服务器进行管理。 使用的vpn软件:pptpd 下载地址:http://poptop.sourceforge.net/yum/stable/rhel5/x86_64/ 需要安装的软件ppp 首先下载pptpd和ppp两个软件到服务器上 分别进行安装 #wgethttp://poptop.sourceforge.net/yum/stable/rhel5/x86_64/pptpd-1.3.4-2.rhel5.x86_64.rpm #wgethttp://poptop.sourceforge.net/yum/stable/rhel5/x86_64/ppp-2.4.4-14.1.rhel5.x86_64.rpm 缺少依赖的话使用yum进行安装一下 #rpm -Uvh pptpd-13.4-2.rhel5.x86_64.rpmppp-2.4.4-14.1.rhel5.x86_64.rpm 修改sysctl.conf 里面的net.ipv4.ip_forward 的值为1 # Controls IP packet forwarding net.ipv4.ip_forward = 1 #sysctl -p 添加iptables; #iptables -t nat -A POSTROUTING -s 172.16.0.0/255.255.255.0 -j SNAT –to-source serverip 修改配置文件 /etc/pptpd.conf下面添加:localip 172.16.0.20remoteip 172.16.0.21-30 /etc/ppp/options.pptpd下面添加:ms-dns 8.8.8.8ms-dns 8.8.4.4 /etc/ppp/chap-secrets添加用户:# client server secret IP addresses test pptpd test *启动pptpd: #/etc/init.d/pptpd [...]



Published by
Published by xFruits
Original source : http://www.vpn123.tk/?p=649...

No comments:

Post a Comment