Home Tutorial Konfigurasi router di linux debian
formats

Konfigurasi router di linux debian

Published on January 18, 2016, by in Tutorial.

Cara konfigurasi router di linux debian

Edit file interface network :

# nano /etc/network/interfaces

Konfigurasi ip serperti berikut :

auto eth0

iface eth0 inet static

          address 192.168.123.1

          netmask 255.255.255.0

          network 192.168.123.0

          broadcast 192.168.123.255

          gateway 192.168.123.1

auto eth1

iface eth1 inet static

          address 192.168.202.1

          netmask 255.255.255.240

          network 192.168.202.0

          broadcast 192.168.202.255

Simpan konfigurasi tersebut.

Tambah nameserver pada resolv.conf

# nano /etc/resolv.conf

nameserver 8.8.8.8

Lanjutkan dengan konfigurasi berikut :

nano /etc/rc.local

iptables -t nat -A POSTROUTING -j MASQUERADE
exit0

Konfigurasi pada sysctl.conf

# nano /etc/sysctl.conf

net.ipv4.ip_forward=1

restart server, tes ping pada ip yang telah dibuat. Semoga bermanfaat.

Leave a Reply

Your email address will not be published. Required fields are marked *