Install the PPTP service and run the following command [html] viewplaincopyprint? Wgethttp: // www.5yun.org/Soft/linux/Openvz-vpn/openvps_vpn_centos-5-6.shchmod install PPTP service
Run the following command:
[Html]View plaincopyprint?
- Wget http://www.5yun.org/Soft/linux/Openvz-vpn/openvps_vpn_centos-5-6.sh
- Chmod a + x openvps_vpn_centos-5-6.sh
- Bash openvps_vpn_centos-5-6.sh
- # If the preceding address is unavailable, try the following command,
- # This script only provides three options. Generally, you can select 1 to automatically complete the entire process.
- # Remove The Annotator
- # Wget http://www.hi-vps.com/shell/vpn_centos6.sh
- # Chmod a + x vpn_centos6.sh
- # Bash vpn_centos6.sh
Wget http://www.5yun.org/Soft/linux/Openvz-vpn/openvps_vpn_centos-5-6.shchmod a + x openvps_vpn_centos-5-6.sh bash openvps_vpn_centos-5-6.sh # if the above address is not available, try the following command, # This script provides only three options, generally select 1 to automatically complete the whole process # Remove the annotator # wget http://www.hi-vps.com/shell/vpn_centos6.sh#chmod a + x vpn_centos6.sh # bash vpn_centos6.sh
The first step is to obtain an automatic script, the second step is to grant it the permission to run, and the third step is to run the script. Sometimes the first step Fails. in this case, you can download the file locally and then upload it to VPS using Putty or SSH client.
After executing the preceding command, a prompt message is returned for selecting the system version. because centos6 was selected previously, select 2nd items, enter 2, and press enter:
[Html]View plaincopyprint?
- Please select your operation system
- Which do you want? Input the number.
- 1. my system is centos5 32bit (only support 32bit)
- 2. my system is centos6 32bit or 64bit (they are support)
- 3. repaire VPN service
- 4. add VPN user
please select your operation systemwhich do you want to?input the number.1. my system is centos5 32bit(only support 32bit)2. my system is centos6 32bit or 64bit(they are support)3. repaire VPN service4. add VPN user
After the command is executed, it will be automatically installed. after successful installation, the following information will be returned:
VPN service is installed, your VPN username is vpn_name, VPN password is **
This prompt indicates that an account named vpn_name has been successfully created and the password is **.
The error 404 is reported after the command is executed, or the file or directory does not exist because the installation package cannot be downloaded successfully.
Here, you can download the installation package manually.
For centos6, run the following command:
[Html]View plaincopyprint?
- Wget http://linux.dell.com/dkms/permalink/dkms-2.0.17.5-1.noarch.rpm
- Wget https://acelnmp.googlecode.com/files/kernel_ppp_mppe-1.0.2-3dkms.noarch.rpm
- Wget https://qiaodahai.googlecode.com/files/pptpd-1.3.4-2.el6.i686.rpm
- Wget https://logdns.googlecode.com/files/ppp-2.4.5-17.0.rhel6.i686.rpm
wget http://linux.dell.com/dkms/permalink/dkms-2.0.17.5-1.noarch.rpmwget https://acelnmp.googlecode.com/files/kernel_ppp_mppe-1.0.2-3dkms.noarch.rpmwget https://qiaodahai.googlecode.com/files/pptpd-1.3.4-2.el6.i686.rpmwget https://logdns.googlecode.com/files/ppp-2.4.5-17.0.rhel6.i686.rpm
Add your own VPN account
How do I add my own vpn account name? For example, if you want to use the account anonymous, set the password to abc @ 123 (note: Dangerous! For demonstration purposes only. do not set such a password !)
Run the following code to add a vpn account:
bash openvps_vpn_centos-5-6.sh
Select 4th items in the returned information option: 4.add VPN user
Enter the user name as prompted, such as anonymous, and then enter the password to complete the vpn setup.
During use, create a VPN connection locally, enter the VPS address and port for the address and port, enter the user name and password of the VPN set by yourself, and then connect.