Pada gambar di atas telah diinstalasi dua vyatta dengan nama host R0 dan R1. Masing-masingnya terdapat tiga interface ethernet dengan nama eth0 (eksternal) serta eth1 dan eth2 (internal). Nilai alamat IP masing-masing interface adalah sebagai berikut:
Hostname | eth0 | eth1 | eth2 |
R0 | 192.168.3.5/30 | 192.168.1.1/24 | 192.168.2.1/24 |
R1 | 192.168.3.6/30 | 192.168.4.1/24 | 192.168.5.1/24 |
Konfigurasi Vyatta-R0:
vyatta@vyatta:~$ configure
vyatta@vyatta# set system host-name R0
vyatta@vyatta# set system domain-name office1.net
vyatta@vyatta# commit
vyatta@R0# set interfaces ethernet eth0 address 192.168.3.5/30
vyatta@R0# set interfaces ethernet eth1 address 192.168.1.1/24
vyatta@R0# set interfaces ethernet eth2 address 192.168.2.1/24
vyatta@R0# commit
vyatta@R0# set protocols static route 0.0.0.0/0 next-hop 192.168.3.6
vyatta@R0# commit
vyatta@R0# set service dhcp-server shared-network-name r0lan1 subnet 192.168.1.0/24 start 192.168.1.10 stop 192.168.1.250
vyatta@R0# set service dhcp-server shared-network-name r0lan1 subnet 192.168.1.0/24 default-router 192.168.1.1
vyatta@R0# commit
vyatta@R0# set service dhcp-server shared-network-name r0lan2 subnet 192.168.2.0/24 start 192.168.2.10 stop 192.168.2.250
vyatta@R0# set service dchp-server shared-network-name r0lan2 subnet 192.168.2.0/24 default-router 192.168.2.1
vyatta@R0# commit
vyatta@R0# save
vyatta@R0# exit
vyatta@R0:~$ logout
Konfigurasi Vyatta-R1:
vyatta@vyatta:~$ configure
vyatta@vyatta# set system host-name R1
vyatta@vyatta# set system domain-name office2.net
vyatta@vyatta# commit
vyatta@R1# set interfaces ethernet eth0 address 192.168.3.6/30
vyatta@R1# set interfaces ethernet eth1 address 192.168.4.1/24
vyatta@R1# set interfaces ethernet eth2 address 192.168.5.1/24
vyatta@R1# commit
vyatta@R1# set protocol static route 0.0.0.0/0 next-hop 192.168.3.5
vyatta@R1# commit
vyatta@R1# set service dhcp-server shared-network-name r1lan1 subnet 192.168.4.0/24 start 192.168.4.10 stop 192.168.4.250
vyatta@R1# set service dhcp-server shared-network-name r1lan1 subnet 192.168.4.0/24 default-router 192.168.4.1
vyatta@R1# commit
vyatta@R1# set service dhcp-server shared-network-name r1lan2 subnet 192.168.5.0/24 start 192.168.5.10 stop 192.168.5.250
vyatta@R1# set service dchp-server shared-network-name r1lan2 subnet 192.168.5.0/24 default-router 192.168.5.1
vyatta@R1# commit
vyatta@R1# save
vyatta@R1# exit
vyatta@R1:~$ logout
0 C0Mm3nTs:
Posting Komentar