RSS

Studi Kasus Vyatta VC4.0.2: NAT Gateway Ke Jardiknas

29 Mei

Artikel ini memaparkan proses konfigurasi vyatta yang digunakan untuk koneksi ke jaringan Jardiknas dengan metode NAT. Skenario topologi seperti di bawah ini:

vytdiknas

Untuk IP client di setiap subnet digunakan dhcp dengan jangkauan .10 s/d .250.

Dari gambar di atas di tetapkan alamat IP sebagai berikut:

Hostname eth0 eth1 eth2
PNP 118.98.176.218/29 192.168.1.1/24 192.168.2.1/24
Juniper 118.98.176.217/29

dengan alamat IP DNS-1: 118.98.224.2 dan DNS-2: 118.98.224.3

Sekarang kita konfigurasi vyatta dengan login terlebih dahulu, setelah itu ketikkan perintah-perintah seperti di bawah ini:

vyatta@vyatta:~$ configure

vyatta@vyatta# set system host-name pnp

vyatta@vyatta# set system domain-name jardiknas.lan

vyatta@vyatta# set system name-server 118.98.224.2

vyatta@vyatta# set system name-server 118.98.224.3

vyatta@vyatta# set system gateway-address 118.98.176.217

vyatta@vyatta# commit

vyatta@pnp# set interfaces ethernet eth0 address 118.98.176.218/29

vyatta@pnp# set interfaces ethernet eth0 description “Jardiknas”

vyatta@pnp# set interfaces ethernet eth1 address 192.168.1.1/24

vyatta@pnp# set interfaces ethernet eth1 description “LANnet-1”

vyatta@pnp# set interfaces ethernet eth2 address 192.168.2.1/24

vyatta@pnp# set interfaces ethernet eth2 description “LANnet-2”

vyatta@pnp# commit

vyatta@pnp# set service dhcp-server shared-network-name LANnet1 subnet 192.168.1.0/24 start 192.168.1.10 stop 192.168.1.250

vyatta@pnp# set service dhcp-server shared-network-name LANnet1 subnet 192.168.1.0/24 default-router 192.168.1.1

vyatta@pnp# set service dhcp-server shared-network-name LANnet1 subnet 192.168.1.0/24 dns-server 118.98.224.2

vyatta@pnp# set service dhcp-server shared-network-name LANnet1 subnet 192.168.1.0/24 dns-server 118.98.224.3

vyatta@pnp# commit

vyatta@pnp# set service dhcp-server shared-network-name LANnet2 subnet 192.168.2.0/24 start 192.168.2.10 stop 192.168.2.250

vyatta@pnp# set service dhcp-server shared-network-name LANnet2 subnet 192.168.2.0/24 default-router 192.168.2.1

vyatta@pnp# set service dhcp-server shared-network-name LANnet2 subnet 192.168.2.0/24 dns-server 118.98.224.2

vyatta@pnp# set service dhcp-server shared-network-name LANnet2 subnet 192.168.2.0/24 dns-server 118.98.224.3

vyatta@pnp# commit

vaytta@pnp# set service nat rule 1 source-address 192.168.0.0/16

vyatta@pnp# set service nat rule 1 outbound-interface eth0

vyatta@pnp# set service nat rule 1 type masquerade

vyatta@pnp# commit

vyatta@pnp# set firewall name ALLOW_ESTABLISHED

vyatta@pnp# set firewall name ALLOW_ESTABLISHED rule 10

vyatta@pnp# set firewall name ALLOW_ESTABLISHED rule 10 action accept

vyatta@pnp# set firewall name ALLOW_ESTABLISHED rule 10 state established enable

vyatta@pnp# commit

vyatta@pnp# set interfaces ethernet eth0 firewall in name ALLOW_ESTABLISHED

vyatta@pnp# set interfaces ethernet eth0 firewall local name ALLOW_ESTABLISHED

vyatta@pnp# commit

vyatta@pnp# exit

vyatta@pnp:~$ logout

 
Tinggalkan komentar

Ditulis oleh pada 29 Mei 2011 in CentOS

 

Tag:

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s

 
%d blogger menyukai ini: