Tinc as VPN

tinc - VPN daemon for Linux. Not so widely spread as OpenVPN, but not inferior to it in functionality. Below i will tell how to setup VPN between 2 Linux servers, one is said to be gateway, another server (client) that has access to the Internet via VPN gateway.

I run two Debian-like servers, gateway has ssh access (via private key) to client. I advice you to setup passwordless SSH access, otherwise i'll type in your password many times.

Gateway setup (gw_tinc.sh and script below are taken from here):

# ./gw_tinc.sh gateway

After executing this command there should be 1 tun0 device in your system. Command should be executed at the very beginning, before you define any client. If everything is ok, setup a client connection:

# ./cl_tinc.sh client

If you see some successfull pings in log, that means it's ok. Script also asks whether you want or not to install VPN gateway as default gateway.

I you have any questions, please feedback.

Теги → tinc vpn