Cara Menggabungkan Beberapa VLAN dengan Router


   

          Setelah kita belajar membuat VLAN yang sederhana sampai dengan trunk cable. Saya akan memberikan contoh Cara Menggabungkan Beberapa VLAN dengan RouteKegunaanya untuk apa? Agar VLAN yang kita buat dapat saling berkomunikasi, walaupun berbeda jaringan.



Membuat VLAN
Switch>
Switch>en
Switch#conf t
Switch(config)#
Switch(config)#vlan 2
Switch(config-vlan)#name Produksi
Switch(config-vlan)#vlan 3
Switch(config-vlan)#name QC
Switch(config-vlan)#vlan 4
Switch(config-vlan)#name HRD
Switch(config-vlan)#
Switch(config-vlan)#end
Melihat Hasil VLAN
Switch#
Switch#sh vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4
Fa0/5, Fa0/6, Fa0/7, Fa0/8
Fa0/9, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Fa0/19, Fa0/20
Fa0/21, Fa0/22, Fa0/23, Fa0/24
2 Produksi active
3 QC active
4 HRD active
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Menambahkan Anggota VLAN
Switch#conf t
Switch(config)#
Switch(config)#vlan 2
Switch(config-vlan)#int f0/1
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 2
Switch(config-if)#int f0/2
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 2
Switch(config-if)#int f0/3
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 3
Switch(config-if)#int f0/4
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 3
Switch(config-if)#int f0/5
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 4
Switch(config-if)#int f0/6
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 4
Switch(config-if)#end

Melihat Hasil VLAN setelah ditambahkan anggotanya

Switch#sh vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/7, Fa0/8, Fa0/9, Fa0/10
Fa0/11, Fa0/12, Fa0/13, Fa0/14
Fa0/15, Fa0/16, Fa0/17, Fa0/18
Fa0/19, Fa0/20, Fa0/21, Fa0/22
Fa0/23, Fa0/24
 
2 Produksi active Fa0/1, Fa0/2
3 QC active Fa0/3, Fa0/4
4 HRD active Fa0/5, Fa0/6
 
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Switch#
Switch#sh vlan id 2
VLAN Name Status Ports
—- ——————————– ——— ——————————-
2 Produksi active Fa0/1, Fa0/2
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
—- —– ———- —– —— —— ——– —- ——– —— ——
2 enet 100002 1500 – – – – – 0 0
Switch#sh vlan name QC
VLAN Name Status Ports
—- ——————————– ——— ——————————-
3 QC active Fa0/3, Fa0/4
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
—- —– ———- —– —— —— ——– —- ——– —— ——
3 enet 100003 1500 – – – – – 0 0

Tambah Lagi Anggota VLAN

Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#vlan 2
Switch(config-vlan)#int f0/7
Switch(config-if)#sw mo ac
Switch(config-if)#sw ac vlan 2
Switch(config-if)#
Switch(config-if)#vlan 3
Switch(config-vlan)#int f0/8
Switch(config-if)#sw mo ac
Switch(config-if)#sw ac vlan 3
Switch(config-if)#
Switch(config-if)#vlan 4
Switch(config-vlan)#int f0/9
Switch(config-if)#sw mo ac
Switch(config-if)#sw ac vlan 4
Switch(config-if)#
Switch(config-if)#end

Hasil VLAN Produksi

Switch#
Switch#sh vlan name Produksi
VLAN Name Status Ports
—- ——————————– ——— ——————————-
2 Produksi active Fa0/1, Fa0/2, Fa0/7
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
—- —– ———- —– —— —— ——– —- ——– —— ——
2 enet 100002 1500 – – – – – 0 0
Switch#show vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/10, Fa0/11, Fa0/12, Fa0/13
Fa0/14, Fa0/15, Fa0/16, Fa0/17
Fa0/18, Fa0/19, Fa0/20, Fa0/21
Fa0/22, Fa0/23, Fa0/24
2 Produksi active Fa0/1, Fa0/2, Fa0/7
3 QC active Fa0/3, Fa0/4, Fa0/8
4 HRD active Fa0/5, Fa0/6, Fa0/9
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Switch#
Switch#

Cara Menghapus Anggota VLAN

Switch#config t
Switch(config)#int f0/7
Switch(config-if)#no switchport mode access
Switch(config-if)#no switchport access vlan Produksi
Switch(config-if)#end
Switch#
Switch#show vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/7, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Fa0/19, Fa0/20
Fa0/21, Fa0/22, Fa0/23, Fa0/24
2 Produksi active Fa0/1, Fa0/2
3 QC active Fa0/3, Fa0/4, Fa0/8
4 HRD active Fa0/5, Fa0/6, Fa0/9
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Switch#

Cara Simpan Hasil Konfigurasi

Switch#
Switch#copy run start
Destination filename [startup-config]?
Building configuration…
[OK]
Switch#
Switch#
Switch#show startup-config
Using 1371 bytes
!
version 12.1
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
spanning-tree mode pvst
!
interface FastEthernet0/1
switchport access vlan 2
switchport mode access
!
interface FastEthernet0/2
switchport access vlan 2
switchport mode access
!
interface FastEthernet0/3
switchport access vlan 3
switchport mode access
==more==

Cara Menghapus VLAN

Switch#
Switch#
Switch#show vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/7, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Fa0/19, Fa0/20
Fa0/21, Fa0/22, Fa0/23, Fa0/24
2 Produksi active Fa0/1, Fa0/2
3 QC active Fa0/3, Fa0/4, Fa0/8
4 HRD active Fa0/5, Fa0/6, Fa0/9
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Switch#
Switch#config t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#
Switch(config)#no vlan 2
Switch(config)#no vlan 3
Switch(config)#no vlan 4
Switch(config)#
Switch(config)#end
Switch#show vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/7, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Fa0/19, Fa0/20
Fa0/21, Fa0/22, Fa0/23, Fa0/24
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Cara Mengembalikan Setting NVRAM ke Running Config
Switch#
Switch#
Switch#copy start run
Destination filename [running-config]?
1371 bytes copied in 0.416 secs (3295 bytes/sec)
Switch#
Switch#
Switch#show vlan brief
VLAN Name Status Ports
—- ——————————– ——— ——————————-
1 default active Fa0/7, Fa0/10, Fa0/11, Fa0/12
Fa0/13, Fa0/14, Fa0/15, Fa0/16
Fa0/17, Fa0/18, Fa0/19, Fa0/20
Fa0/21, Fa0/22, Fa0/23, Fa0/24
2 VLAN0002 active Fa0/1, Fa0/2
3 VLAN0003 active Fa0/3, Fa0/4, Fa0/8
4 VLAN0004 active Fa0/5, Fa0/6, Fa0/9
1002 fddi-default active
1003 token-ring-default active
1004 fddinet-default active
1005 trnet-default active
Setting Mode Trunk Switch
Switch#conf t
Switch(config)#
Switch(config)#int fa0/24
Switch(config-if)#switchport mode trunk
Switch(config-if)#
Switch(config-if)#end\




Cara setting Router penghubung VLAN

Continue with configuration dialog? [yes/no]: n
Press RETURN to get started!
Router>
Router>en
Router#
Router#config t
Router(config)#hostname cisco.pintar.id
cisco.pintar.id(config)#interface fa0/0.2
cisco.pintar.id(config-subif)#encapsulation dot1q 2
cisco.pintar.id(config-subif)#ip address 192.168.10.100 255.255.255.0
cisco.pintar.id(config-subif)#
cisco.pintar.id(config-subif)#interface fa0/0.3
cisco.pintar.id(config-subif)#encapsulation dot1q 3
cisco.pintar.id(config-subif)#ip address 192.168.20.100 255.255.255.0
cisco.pintar.id(config-subif)#
cisco.pintar.id(config-subif)#interface fa0/0.4
cisco.pintar.id(config-subif)#encapsulation dot1q 4
cisco.pintar.id(config-subif)#ip address 192.168.30.100 255.255.255.0
cisco.pintar.id(config-subif)#
cisco.pintar.id(config-subif)#
cisco.pintar.id(config-subif)#end
cisco.pintar.id#config t
cisco.pintar.id(config)#int fa0/0
cisco.pintar.id(config-if)#no shut
cisco.pintar.id(config-if)#end
cisco.pintar.id#
cisco.pintar.id#ping 192.168.20.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.20.2, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 0/1/3 ms
cisco.pintar.id#ping 192.168.20.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.20.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 0/0/1 ms



Post a Comment

0 Comments