Perancangan Virtual Local Area Network (Vlan) Dengan Dynamic Routing Menggunakan Cisco Packet Tracer 5.33

LAMPIRAN I
1. Router Cisco 2620XM
Pemberian nama pada router :
Router>en
Router#config terminal
Enter

configuration

commands,

one

per

line.

End

with


CNTL/Z.
Router(config)#hostname R1
R1(config)#end
R1#
%SYS-5-CONFIG_I: Configured from console by console
R1#

Langkah pemberian IP address sub-interface untuk masing-masing VLAN di
dalam router:
R1>en
R1#config terminal
Enter

configuration

commands,

one

per


line.

End

with

CNTL/Z.
R1(config)#int f0/0
R1(config-if)#no shutdown

R1(config-if)#
%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to
up

67
Universitas Sumatera Utara

%LINEPROTO-5-UPDOWN:


Line

protocol

on

Interface

FastEthernet0/0, changed state to up

R1(config-if)#int f0/0.1

%LINK-5-CHANGED: Interface FastEthernet0/0.1, changed state
to up

%LINEPROTO-5-UPDOWN:

Line

protocol


on

Interface

FastEthernet0/0.1, changed state to up
R1(config-subif)#encapsulation dot1q 1
R1(config-subif)#ip add 192.168.1.1 255.255.255.0
R1(config-subif)#int f0/0.2

%LINK-5-CHANGED: Interface FastEthernet0/0.2, changed state
to up

%LINEPROTO-5-UPDOWN:

Line

protocol

on


Interface

FastEthernet0/0.2, changed state to up
R1(config-subif)#encapsulation dot1q 2
R1(config-subif)#ip address 192.168.2.1 255.255.255.0
R1(config-subif)#int f0/0.3

%LINK-5-CHANGED: Interface FastEthernet0/0.3, changed state
to up

%LINEPROTO-5-UPDOWN:

Line

protocol

on

Interface


FastEthernet0/0.3, changed state to up

68
Universitas Sumatera Utara

R1(config-subif)#encapsulation dot1q 3
R1(config-subif)#ip address 192.168.3.1 255.255.255.0
R1(config-subif)#int f0/0.4

%LINK-5-CHANGED: Interface FastEthernet0/0.4, changed state
to up

%LINEPROTO-5-UPDOWN:

Line

protocol

on


Interface

FastEthernet0/0.4, changed state to up
R1(config-subif)#encapsulation dot1q 4
R1(config-subif)#ip address 192.168.4.1 255.255.255.0
R1(config-subif)#int f0/0.5

%LINK-5-CHANGED: Interface FastEthernet0/0.5, changed state
to up

%LINEPROTO-5-UPDOWN:

Line

protocol

on

Interface


FastEthernet0/0.5, changed state to up
R1(config-subif)#encapsulation dot1q 5
R1(config-subif)#ip address 192.168.5.1 255.255.255.0
R1(config-subif)#exit
R1(config)#end
R1#
%SYS-5-CONFIG_I: Configured from console by console

Langkah mengaktifkan konfigurasi Dynamic Routing RIP version 2 di dalam
router :
R1>en

69
Universitas Sumatera Utara

R1#config terminal
Enter

configuration


commands,

one

per

line.

End

with

CNTL/Z.
R1(config)#router rip
R1(config-router)#network 192.168.1.0
R1(config-router)#network 192.168.2.0
R1(config-router)#network 192.168.3.0
R1(config-router)#network 192.168.4.0
R1(config-router)#network 192.168.5.0

R1(config-router)#version 2
R1(config-router)#no auto summary
R1(config-router)#exit
R1(config)#end
R1#
%SYS-5-CONFIG_I: Configured from console by console

Langkah untuk mengaktifkan konfigurasi DHCP untuk masing-masing VLAN :
R1>en
R1#config terminal
Enter

configuration

commands,

one

per


line.

End

with

CNTL/Z.
R1(config)#int f0/0.2
R1(config-subif)#ip dhcp pool HRD
R1(dhcp-config)#network 192.168.2.0 255.255.255.0
R1(dhcp-config)#default-router 192.168.2.1
R1(dhcp-config)#dns-server 8.8.8.8
R1(dhcp-config)#ip

dhcp

excluded-address

192.168.2.1

192.168.2.2

70
Universitas Sumatera Utara

R1(config)#exit
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
R1(config)#int f0/0.3
R1(config-subif)#ip dhcp pool Keuangan
R1(dhcp-config)#network 192.168.3.0 255.255.255.0
R1(dhcp-config)#default-router 192.168.3.1
R1(dhcp-config)#dns-server 8.8.8.8
R1(dhcp-config)#ip

dhcp

excluded-address

192.168.3.1

192.168.3.2
R1(config)#exit
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
R1(config)#int f0/0.4
R1(config-subif)#ip dhcp pool IT
R1(dhcp-config)#network 192.168.4.0 255.255.255.0
R1(dhcp-config)#default-router 192.168.4.1
R1(dhcp-config)#dns-server 8.8.8.8
R1(dhcp-config)#ip

dhcp

excluded-address

192.168.4.1

192.168.4.2

71
Universitas Sumatera Utara

R1(config)#exit
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
R1(config)#int f0/0.5
R1(config-subif)#ip dhcp pool Penjualan
R1(dhcp-config)#network 192.168.5.0 255.255.255.0
R1(dhcp-config)#default-router 192.168.5.1
R1(dhcp-config)#dns-server 8.8.8.8
R1(dhcp-config)#ip

dhcp

excluded-address

192.168.5.1

192.168.5.2
R1(config)#exit
R1#
%SYS-5-CONFIG_I: Configured from console by console

2. Switch VLAN
Membuat VLAN database :
Switch>enable
Switch#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
Switch(config)#hostname Switch-VLAN
Switch-VLAN(config)#^Z
Switch-VLAN#
%SYS-5-CONFIG_I: Configured from console by console

72
Universitas Sumatera Utara

Switch-VLAN#vlan database
% Warning: It is recommended to configure VLAN from config
mode,
as VLAN database mode is being deprecated. Please consult
user
documentation for configuring VTP/VLAN in config mode.

Switch-VLAN(vlan)#vlan 2 name HRD
VLAN 2 added:
Name: HRD
Switch-VLAN(vlan)#vlan 3 name Keuangan
VLAN 3 added:
Name: Keuangan
Switch-VLAN(vlan)#vlan 4 name IT
VLAN 4 added:
Name: IT
Switch-VLAN(vlan)#vlan 5 name Penjualan
VLAN 5 added:
Name: Penjualan
Switch-VLAN(vlan)#exit
APPLY completed.
Exiting....

Mengaktifkan koneksi VLAN ke router /naik ke layer 3 inter-VLAN routing :
Switch-VLAN#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
Switch-VLAN(config)#int f0/1

73
Universitas Sumatera Utara

Switch-VLAN(config-if)#switchport mode trunk
%LINEPROTO-5-UPDOWN:

Line

protocol

on

Interface

on

Interface

FastEthernet0/1, changed state to down
%LINEPROTO-5-UPDOWN:

Line

protocol

FastEthernet0/1, changed state to up
Switch-VLAN(config-if)#end
Switch-VLAN#
%SYS-5-CONFIG_I: Configured from console by console

Pemberian membership pada VLAN atau IP subnet address based :
Switch-VLAN#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
Switch-VLAN(config)#int f0/2
Switch-VLAN(config-if)#switchport mode access
Switch-VLAN(config-if)#switchport access vlan 2
Switch-VLAN(config-if)#int f0/3
Switch-VLAN(config-if)#switchport mode access
Switch-VLAN(config-if)#switchport access vlan 3
Switch-VLAN(config-if)#int f0/4
Switch-VLAN(config-if)#switchport mode access
Switch-VLAN(config-if)#switchport access vlan 4
Switch-VLAN(config-if)#int f0/5
Switch-VLAN(config-if)#switchport mode access
Switch-VLAN(config-if)#switchport access vlan 5
Switch-VLAN(config-if)#end
Switch-VLAN#
%SYS-5-CONFIG_I: Configured from console by console

74
Universitas Sumatera Utara

Setting Default-gateway pada VLAN 1 :
Switch-VLAN#config terminal
Enter

configuration

commands,

one

per

line.

End

with

CNTL/Z.
Switch-VLAN(config)#int vlan 1
Switch-VLAN(config-if)#ip address 192.168.1.2 255.255.255.0
Switch-VLAN(config-if)#no shutdown
%LINK-5-CHANGED: Interface Vlan1, changed state to up
Switch-VLAN(config-if)#
%LINEPROTO-5-UPDOWN:

Line

protocol

on

Interface

Vlan1,

changed state to up
Switch-VLAN(config-if)#exit
Switch-VLAN(config)#ip default-gateway 192.168.1.1
Switch-VLAN(config)#end
Switch-VLAN#
%SYS-5-CONFIG_I: Configured from console by console

75
Universitas Sumatera Utara