Installasi tinc-vpn di linux

Kita akan install Tinc vpn di 2 buah komputer dengan nama jaringan myvpn

Pastikan firewall membuka port 655 dan yang perlu diperhatikan folder dan file yang akan dibuat secara manual sbb:

/usr/local/etc/tinc/
                             /myvpn/
                                        tinc.conf
                                        tinc-up
                                        tinc-down
                                       /hosts/
                                                 server
                                                 client


Lakukan di kedua Komputer langkah ini:

1. Download file tar.gz di www.tinc-vpn.org kemudian lakukan installasi
2. masuk ke folter /usr/local/etc

cd /usr/local/etc
mkdir -p tinc/myvpn/hosts
cd /usr/local/
mkdir -p var/run
masuk ke folder myvpn dan buat file tinc.conf
cd /usr/local/etc/tinc/myvpn
vi tinc.conf

di komptuer 1 masukan di tinc.conf dengan :

# ------- server -------
Name = server
Device = /dev/net/tun
ConnectTo = client

di komptuer 2 masukan di tinc.conf dengan :


# ------- client -------
Name = client
Device = /dev/net/tun
ConnectTo = server


di kedua komputer lakukan perintah :

tincd -n myvpn -K

akan terbentuk file private key dan public_key.

masuk ke folder hosts akan secara otomatis  ada file server dan client dan lakukan edit di masing masing komputer. tambahkan diatas public key yang sudah ada kode berikut :

di komputer1 (server) :


# ------- server -------
# /usr/local//etc/tinc/myvpn/hosts/server
Address = 222.222.222.222 (ip public komputer1)
Subnet = 10.0.7.1/32
# Public key dibawah ini

di komputer 2 (client)

# ------- client -------
# /usr/local/etc/tinc/myvpn/hosts/client
Address = 111.111.111.111 (ip public komputer2)
Subnet = 10.0.7.2/32
# Public key dibawah ini


langkah terikahir di masing-masing komputer buat 2 file tinc-up dan tinc-down

di komputer 1

# /usr/local/etc/tinc/myvpn/tinc-up
ifconfig $INTERFACE 10.0.7.1 netmask 255.255.255.0

# /usr/local/etc/tinc/myvpn/tinc-down
ifconfig $INTERFACE down

di komputer 2

# /usr/local/etc/tinc/myvpn/tinc-up
ifconfig $INTERFACE 10.0.7.2 netmask 255.255.255.0

# /usr/local/etc/tinc/myvpn/tinc-down
ifconfig $INTERFACE down

berikan hak akses ke file-file tinc

chmod u+x /usr/local/etc/tinc/myvpn/tinc-*
sampai disini konfigurasi tinc vpn sudah selesai. aktipkan dengan perintah :

/usr/local/sbin/tincd -n myvpn -d3


untuk memastikan kedua komputer terhubung, lakukan ping ke ip address yang dikonfigurasikan.

Untuk menelusuri kesalahan konfigurasi dapat memberikan perintah: 

tincd -n myvpn -d5 -D

Comments

joemill00077711 said…
A powerful share, I simply given this onto a colleague who was doing just a little analysis on this. And he in truth bought me breakfast as a result of I discovered it for him.. smile. So let me reword that: Thnx for the treat! However yeah Thnkx for spending the time to discuss this, I really feel strongly about it and love studying more on this topic. If attainable, as you develop into expertise, would you mind updating your weblog with extra particulars? It is highly helpful for me. Large thumb up for this blog post! casino bonus
mrtttony002 said…
This website is mostly a stroll-by means of for the entire information you wished about this and didn’t know who to ask. Glimpse here, and also you’ll definitely discover it. online casino

Popular posts from this blog

Persyaratan Domain .id Indonesia

Cara Upload file dengan Software FTP ke server hosting

Cara mengaktipkan CloudFlare di cpanel hosting agar websites lebih cepat diakses