Centos-VPN refers to the local area Network configuration and the full name of VPN is "Virtual Private Network", which is translated as "Virtual Private Network ". As the name suggests, we can regard a virtual private network as an internal private line of an enterprise. It can establish a proprietary communication line between two or more enterprise intranets connected to the Internet in different places through special encrypted communication protocols, it is like setting up a leased line, but it does not need to lay physical lines such as optical cables. This is like applying for a leased line from the telecommunications board, but there is no need to pay for the laying of the line, or purchase a router or other hardware equipment. VPN technology was originally one of the most important technologies of routers. Currently, VPN functions are also supported in vswitches, firewall devices, Windows, and other software, the core of a VPN is to use a public network to establish a virtual private network. A Virtual Private Network (VPN) is defined as a temporary and secure connection through a public network (usually the internet). It is a secure and stable tunnel through a chaotic public network. A Virtual Private Network is an extension of the enterprise intranet. Virtual Private Network can help remote users, company branches, business partners and suppliers to establish trusted and secure connections with the company's Intranet, and ensure secure data transmission. A virtual private network can be used for the global Internet access of increasing mobile users to achieve secure connections. It can be used to implement virtual private lines for secure communication between enterprise websites, it is used to economically and effectively connect commercial partners and users to a secure, out-of-network virtual private network. PPTP is called Point to Point Tunneling Protocol-Point to Point tunnel Protocol, which is a type of VPN Protocol. 1, CentOS 5.3 pptp vpn Server installation 1, install related software 32-bit edition: yum install-y ppp iptableswget http://poptop.sourceforge.net/yum/stable/packages/pptpd-1.3.4-2.rhel5.i386.rpmrpm-ivh pptpd-1.3.4-2.rhel5.i386.rpm 64-bit edition: yum install-y ppp iptableswget http://poptop.sourceforge.net/yum/stable/packages/pptpd-1.3.4-2.rhel5.x86_64.rpmrpm-ivh pptpd-1.3.4-2.rhel5.x86_64.rpm install warning: pptpd-1.3.4-2.rhel5.x86_64.rp if the following error occurs M: Header V3 DSA/SHA1 Signature, key ID 862acc42: NOKEYerror: Failed dependencies: ppp = 2.4.4 is needed by pptpd-1.3.4-2.rhel5.x86_64 wget http://poptop.sourceforge.net/yum/stable/packages/pptpd-1.3.4-2.el6.x86_64.rpm; 2. Compile the configuration file ①. The configuration file/etc/ppp/options.ppt pdmv/etc/ppp/options.ppt pd. bakvi/etc/ppp/options.ppt pd: name pptpdrefuse-paprefuse-chaprefuse-mschaprequire-mscha P-v2require-mppe-128proxyarplocknobsdcompnovjnovjccompnologfdidle 2592000ms-dns 8.8.8.8ms-dns 8.8.4.4 ②, profile/etc/ppp/chap-secretsmv/etc/ppp/chap-secrets/etc/ppp/chap-secrets.bakvi/etc/ppp/chap-secrets enter the following content # Secrets for authentication using CHAP # client server secret IP addressesmyusername pptpd mypassword * Note: here, myusername and mypassword are the logon username and password of pptp vpn. ③. configuration file/etc/pptpd. confmv/etc/pptpd. conf /Etc/pptpd. conf. bakvi/etc/pptpd. enter the following content in the conf file: option/etc/ppp/options.ppt pdlogwtmplocalip 192.168.9.1remoteip 192.168.9.11-30 Note: Assign 192.168.9.11 ~ IP address (4) between 192.168.9.30 and the configuration file/etc/sysctl. confvi/etc/sysctl. conf: net. ipv4.ip _ forward = 1 save and run:/sbin/sysctl-p after exiting 3. start pptp vpn Server:/sbin/service pptpd start 4. start iptables: /sbin/service iptables start/sbin/iptables-t nat-a postrouting-o eth0-s 192.168.9.0/24-j MASQUERADE