UndergroundVPN Command Line Setup in Linux CentOS (PPTP)
This handy how-to guide will help you get UndergroundVPN set up on the CentOS Linux distribution using the PPTP protocol via the command line interface.
- Run the following commands:
sudo yum update
sudo yum install pptp
sudo modprobe nf_conntrack_pptp
sudo modprobe ppp_mppe
- Run sudo nano/etc/ppp/chap-secrets to edit the chap-secrets file as shown below:
vpnusername<space>PPTP<space>vpnpassword<space>*
Press CTRL+O to save the file, and CTRL+X to exit the editor.
- To create a UndergroundVPN file, run sudo nano/etc/ppp/peers/undergroundvpn and enter the following information:
pty “pptp us1.undergroundvpn.net –nolaunchpppd”
name yourVPNusername
remotename PPTP
require-mppe-128
file /etc/ppp/options.pptp
ipparam undergroundvpn
To save the file, press CTRL+O. To exit the editor, press CTRL+X. Please note that we have currently used us1.undergroundvpn.net as the server address. You can choose any server of your choice. The list of servers is available here
- Run the command: sudo nano/etc/ppp/options.pptp. Be sure there is no ‘#’ sign before these lines.
lock
noauth
refuse-pap
refuse-eap
refuse-chap
nobsdcomp
nodeflate
require-mppe-128
Once this is done, Press CTRL+X to exit.
- Run sudo nano /etc/ppp/ip-up.localand add the following line. By doing so, it will set the default route to ppp0.
/sbin/route add default ppp0
To save the file, press CTRL+O. To exit the editor, press CTRL+X.
- In order to execute the file, run: sudo chmod 755 /etc/ppp/ip-up.local
- Connect to the VPN by running sudo pppd call undergroundvpn
- Run curl ipinfo.io to check the accuracy of your VPN IP and location.
- To disconnect the VPN, run sudo pkill pppd
- If you are unable to connect, please check your connection logs by running sudo cat /var/log/messages | grep pppd