| Source: https://forum.ramhost.us/bbs/viewtopic.php?id=4 This tutorial shows you how to install and configure an OpenVPN tunnel on your VPS. Code:# apt-get install openvpn 2) Move some things into the correct place: Code:# cp -R /usr/share/doc/openvpn/examples/easy-rsa /etc/openvpn 3) Generate Server and Client Encryption: Code:# cd /etc/openvpn/easy-rsa/2.0 Press enter at each prompt, and answer yes to all yes/no questions. Code:# chmod 755 /etc/rc.local the default contents of this file are as follows: Code:#!/bin/sh -e We are going to add the following before "exit 0" Code:#!/bin/sh -e 5) Create OpenVPN configuration file: Code:# nano /etc/openvpn/openvpn.conf Insert the following: Code:dev tun 6) Start OpenVPN: Code:# /etc/init.d/openvpn start (Press CTRL+C if the console hangs after running /etc/rc.local) Code:# tail /var/log/syslog You should see something like the following: Code:ovpn-openvpn[3410]: TUN/TAP device tun0 opened Note: If you instead see something like this: Code:Sun Dec 13 08:32:02 2009 Note: Cannot open TUN/TAP dev /dev/net/tun: Operation not permitted (errno=1) And the output of "uptime" shows your server has been running for less than 2 hours, then wait for our cron job to run - which will automatically fix this issue. Code:/etc/openvpn/easy-rsa/2.0/keys/ca.crt And finally, here is an example client configuration (client.ovpn): Code:client -----------
|
Powered by WHMCompleteSolution