ROUTING STATIC DENGAN VLAN
KONFIGURASI VLAN
Konfigurasi Vlan Kantor1
TABEL IP (Lihat Gambar)
Router | IP | Netmask | Interface |
Router_Kantor1 | 192.168.1.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor1 | 192.168.10.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor1 | 10.10.10.1 | 255.255.255.252 | Fa 0/0 |
Router_Kantor2 | 172.168.1.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor2 | 172.168.10.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor2 | 10.10.10.2 | 255.255.255.252 | Fa 0/0 |
Router_Kantor2 | 11.11.11.1 | 255.255.255.252 | Fa 1/0 |
Router_Kantor3 | 197.169.1.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor3 | 197.169.10.1 | 255.255.255.0 | Fa 0/1 |
Router_Kantor3 | 11.11.11.2 | 255.255.255.252 | Fa 0/0 |
ROUTER KANTOR 1
Router_Kantor1
Router>enable
Router#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname router_kantor1
router_kantor1(config)#interface fastEthernet 0/0
router_kantor1(config-if)#exit
router_kantor1(config)#interface fastEthernet 0/1
router_kantor1(config-if)#speed auto
router_kantor1(config-if)#duplex auto
router_kantor1(config-if)#no shutdown
%LINK-5-CHANGED: Interface FastEthernet0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up
router_kantor1(config-if)#exit
router_kantor1(config)#interface fastEthernet 0/1.2
%LINK-5-CHANGED: Interface FastEthernet0/1.2, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1.2, changed state to up
router_kantor1(config-subif)#encapsulation dot1Q 2
router_kantor1(config-subif)#description konek ke vlan2
router_kantor1(config-subif)#ip address 192.168.1.1 255.255.255.0
router_kantor1(config-subif)#no shutdown
router_kantor1(config-subif)#exit
router_kantor1(config)#interface fastEthernet 0/1.3
%LINK-5-CHANGED: Interface FastEthernet0/1.3, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1.3, changed state to up
router_kantor1(config-subif)#encapsulation dot1Q 3
router_kantor1(config-subif)#ip address 192.168.10.1 255.255.255.0
router_kantor1(config-subif)#description konek ke vlan3
router_kantor1(config-subif)#no shutdown
router_kantor1(config-subif)#exit
router_kantor1(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
router_kantor1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
router_kantor1#
SWITCH KANTOR 1
Switch_Kantor1
Switch>enable
Switch#hostname Switch_Kantor1
Switch#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hostname switch_kantor1
switch_kantor1(config)#interface fastEthernet 0/1
switch_kantor1(config-if)#switchport mode trunk
switch_kantor1(config-if)#switchport trunk allowed vlan all
switch_kantor1(config-if)#no shutdown
switch_kantor1(config-if)#end
%SYS-5-CONFIG_I: Configured from console by console
switch_kantor1#vlan 2
switch_kantor1#exit
switch_kantor1 con0 is now available
Press RETURN to get started.
switch_kantor1>enable
switch_kantor1#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
switch_kantor1(config)#vlan 2
switch_kantor1(config-vlan)#name vlan2
switch_kantor1(config-vlan)#vlan 3
switch_kantor1(config-vlan)#name vlan3
switch_kantor1(config-vlan)#exit
switch_kantor1(config)#interface fastEthernet 0/2
switch_kantor1(config-if)#switchport mode access
switch_kantor1(config-if)#switchport access vlan 2
switch_kantor1(config-if)#exit
switch_kantor1(config)#interface fastEthernet 0/3
switch_kantor1(config-if)#switchport mode access
switch_kantor1(config-if)#switchport access vlan 3
switch_kantor1(config-if)#exit
switch_kantor1(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
switch_kantor1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
switch_kantor1#
KONFIGURASI IP KOMPUTER KANTOR 1
Konfigurasi diatas berlaku untuk Konfigurasi VLAN Kantor 2 dan VLAN Kantor 3 hanya saja perbedaannya pada Network Address dan IP tiap komputer di LAN serta Vlan-nya yang berbeda. Berikut konfigurasinya :
Kantor 1 IP Netmask subinterface VLan
LaptopA_Kantor 1 192.168.1.2 255.255.255.0 FastEthernet 0/1.2 Vlan2
LaptopB_Kantor 1 192.168.10.2 255.255.255.0 FastEthernet 0/1.3 Vlan3
Kantor 2 IP Netmask subinterface VLan
KompA_Kantor 2 172.168.1.2 255.255.255.0 FastEthernet 0/1.2 Vlan4
KompB_Kantor 2 172.168.10.2 255.255.255.0 FastEthernet 0/1.3 Vlan5
Kantor 1 IP Netmask subinterface VLan
LaptopA_Kantor 3 197.169.1.2 255.255.255.0 FastEthernet 0/1.2 Vlan6
LaptopB_Kantor 3 197.169.10.2 255.255.255.0 FastEthernet 0/1.3 Vlan7
Konfigurasi Tabel Routing Static
Konfigurasi IP di Router_Kantor1
router_kantor1>enable
router_kantor1#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
router_kantor1(config)#interface fastEthernet 0/0
router_kantor1(config-if)#speed auto
router_kantor1(config-if)#duplex auto
router_kantor1(config-if)#ip address 10.10.10.1 255.255.255.252
router_kantor1(config-if)#description konek ke Router_Kantor2
router_kantor1(config-if)#no shutdown
router_kantor1(config-if)#exit
router_kantor1(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
router_kantor1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
router_kantor1#
Konfigurasi IP di Router_Kantor2
router_kantor2>enable
router_kantor2#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
router_kantor2(config)#interface fastEthernet 0/0
router_kantor2(config-if)#speed auto
router_kantor2(config-if)#duplex auto
router_kantor2(config-if)#ip address 10.10.10.2 255.255.255.252
router_kantor2(config-if)#description konek ke Router_Kantor1
router_kantor2(config-if)#no shutdown
router_kantor2(config-if)#exit
router_kantor2(config)#exit
router_kantor2#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
router_kantor2(config)#interface fastEthernet 1/0
router_kantor2(config-if)#speed auto
router_kantor2(config-if)#duplex auto
router_kantor2(config-if)#ip address 11.11.11.1 255.255.255.252
router_kantor2(config-if)#description konek ke Router_Kantor3
router_kantor2(config-if)#no shutdown
router_kantor2(config-if)#exit
router_kantor2(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
router_kantor2#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
router_kantor2#
Konfigurasi IP di Router_Kantor3
router_kantor3>enable
router_kantor3#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
router_kantor3(config)#interface fastEthernet 0/0
router_kantor3(config-if)#speed auto
router_kantor3(config-if)#duplex auto
router_kantor3(config-if)#ip address 11.11.11.2 255.255.255.252
router_kantor3(config-if)#description konek ke Router_Kantor2
router_kantor3(config-if)#no shutdown
router_kantor3(config-if)#exit
router_kantor3(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
router_kantor2#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
router_kantor3#
Konfigurasi Routing
Tabel Routing
Network | Next Hop |
Router_Kantor1 |
172.168.1.0 | 10.10.10.2 |
172.168.10.0 |
197.169.1.0 |
197.169.10.0 |
11.11.11.0 |
Router_Kantor2 |
192.168.1.0 | 10.10.10.1 |
192.168.10.0 |
197.169.1.0 | 11.11.11.2 |
197.169.10.0 |
Router_Kantor3 |
|
192.168.1.0 | 11.11.11.1 |
192.168.10.0 |
172.168.1.0 |
172.168.10.0 |
10.10.10.0 |
Konfigurasi routing Router_Kantor1
router_kantor1>enable
router_kantor1#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
router_kantor1(config)#ip route 11.11.11.0 255.255.255.252 10.10.10.2
router_kantor1(config)#ip route 172.168.1.0 255.255.255.0 10.10.10.2
router_kantor1(config)#ip route 172.168.10.0 255.255.255.0 10.10.10.2
router_kantor1(config)#ip route 197.169.1.0 255.255.255.0 10.10.10.2
router_kantor1(config)#ip route 197.169.10.0 255.255.255.0 10.10.10.2
router_kantor1(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
router_kantor1#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
10.0.0.0/30 is subnetted, 1 subnets
C 10.10.10.0 is directly connected, FastEthernet0/0
11.0.0.0/30 is subnetted, 1 subnets
S 11.11.11.0 [1/0] via 10.10.10.2
172.168.0.0/24 is subnetted, 2 subnets
S 172.168.1.0 [1/0] via 10.10.10.2
S 172.168.10.0 [1/0] via 10.10.10.2
C 192.168.1.0/24 is directly connected, FastEthernet0/1.2
C 192.168.10.0/24 is directly connected, FastEthernet0/1.3
S 197.169.1.0/24 [1/0] via 10.10.10.2
S 197.169.10.0/24 [1/0] via 10.10.10.2
router_kantor1#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
router_kantor1#
Konfigurasi routing Router_Kantor2
Router_Kantor2>enable
Router_Kantor2#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router_Kantor2(config)#ip route 192.168.1.0 255.255.255.0 10.10.10.1
Router_Kantor2(config)#ip route 192.168.10.0 255.255.255.0 10.10.10.1
Router_Kantor2(config)#ip route 197.169.1.0 255.255.255.0 11.11.11.2
Router_Kantor2(config)#ip route 197.169.10.0 255.255.255.0 11.11.11.2
Router_Kantor2(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
Router_Kantor2#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
10.0.0.0/30 is subnetted, 1 subnets
C 10.10.10.0 is directly connected, FastEthernet0/0
11.0.0.0/30 is subnetted, 1 subnets
C 11.11.11.0 is directly connected, FastEthernet1/0
172.168.0.0/24 is subnetted, 2 subnets
C 172.168.1.0 is directly connected, FastEthernet0/1.2
C 172.168.10.0 is directly connected, FastEthernet0/1.3
S 192.168.1.0/24 [1/0] via 10.10.10.1
S 192.168.10.0/24 [1/0] via 10.10.10.1
S 197.169.1.0/24 [1/0] via 11.11.11.2
S 197.169.10.0/24 [1/0] via 11.11.11.2
Router_Kantor2#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
Router_Kantor2#
Konfigurasi routing Router_Kantor3
Router_Kantor3>enable
Router_Kantor3#config
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router_Kantor3(config)#ip route 192.168.1.0 255.255.255.0 11.11.11.1
Router_Kantor3(config)#ip route 192.168.10.0 255.255.255.0 11.11.11.1
Router_Kantor3(config)#ip route 10.10.10.0 255.255.255.252 11.11.11.1
Router_Kantor3(config)#ip route 172.168.1.0 255.255.255.0 11.11.11.1
Router_Kantor3(config)#ip route 172.168.10.0 255.255.255.0 11.11.11.1
Router_Kantor3(config)#exit
%SYS-5-CONFIG_I: Configured from console by console
Router_Kantor3#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
10.0.0.0/30 is subnetted, 1 subnets
S 10.10.10.0 [1/0] via 11.11.11.1
11.0.0.0/30 is subnetted, 1 subnets
C 11.11.11.0 is directly connected, FastEthernet0/0
172.168.0.0/24 is subnetted, 2 subnets
S 172.168.1.0 [1/0] via 11.11.11.1
S 172.168.10.0 [1/0] via 11.11.11.1
S 192.168.1.0/24 [1/0] via 11.11.11.1
S 192.168.10.0/24 [1/0] via 11.11.11.1
C 197.169.1.0/24 is directly connected, FastEthernet0/1.2
C 197.169.10.0/24 is directly connected, FastEthernet0/1.3
Router_Kantor3#copy running-config startup-config
Destination filename [startup-config]?
Building configuration...
[OK]
Router_Kantor3#
Selesai selamat mencoba dengan tes Ping ke semua device