COnfigurasi router on stick
Langkah-lamgkah
- Buat topologi seperti gambar di atas Jika sudah masuk ke switch lalu di configurasi yang sebelah kiri.
- Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hos
Switch(config)#hostname SW-0
SW-0(config)#int fa0/3
SW-0(config-if)#switchport mode access
SW-0(config-if)#switchport access vlan 10
SW-0(config-if)#exit
SW-0(config)#int range fa0/1-2
SW-0(config-if-range)#switchport mode trunk
SW-0(config-if-range)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to up
SW-0(config-if-range)#exit
SW-0(config)#
- Switch>
Switch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hos
Switch(config)#hostname SW-1
SW-1(config)#int range fa0/22-24
SW-1(config-if-range)#switchport mode access
SW-1(config-if-range)#switchport access vlan 20
SW-1(config-if-range)#exit
SW-1(config)#int ra
SW-1(config)#int range fa0/1-4
SW-1(config-if-range)#sw
SW-1(config-if-range)#switchport mo
SW-1(config-if-range)#switchport mode t
SW-1(config-if-range)#switchport mode trunk
SW-1(config)#int g0/1
SW-1(config-if)#switchport mode trunk
SW-1(config-if)#
SW-1(config-if-range)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/3, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/3, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/4, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/4, changed state to up
SW-1(config-if-range)#vlan 10
SW-1(config-vlan)#exit
SW-1(config)#vlan 30
SW-1(config-vlan)#exit
SW-1(config)# - Switch>
Switch>
Switch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hos
Switch(config)#hostname SW-2
SW-2(config)#int ra
SW-2(config)#int range fa0/23-24
SW-2(config-if-range)#switchport mode access
SW-2(config-if-range)#switchport access vlan 30
SW-2(config-if-range)#exit
SW-2(config)#int range fa0/1-2
SW-2(config-if-range)#switchport mode trunk
SW-2(config-if-range)#exit
SW-2(config)#
2. Configurasi routernya
- Router>ena
Router>enable
Router#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hos
Router(config)#hostname RT-0
RT-0(config)#int g0/0/0
RT-0(config-if)#no sh
RT-0(config-if)#no shutdown
RT-0(config-if)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0/0, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0/0, changed state to up
RT-0(config-if)#int g0/0/0.10
RT-0(config-subif)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0/0.10, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0/0.10, changed state to up
RT-0(config-subif)#encapsulation dot1Q 10
RT-0(config-subif)#ip ad
RT-0(config-subif)#ip address 192.168.10.1 255.255.255.0
RT-0(config-subif)#int g0/0/0.20
RT-0(config-subif)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0/0.20, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0/0.20, changed state to up
RT-0(config-subif)#encapsulation dot1Q 20
RT-0(config-subif)#ip add 192.168.20.1 255.255.255.0
RT-0(config-subif)#int g0/0/0.30
RT-0(config-subif)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0/0.30, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0/0.30, changed state to up
RT-0(config-subif)#en
RT-0(config-subif)#encapsulation d
RT-0(config-subif)#encapsulation dot1Q 30
RT-0(config-subif)#ip add 192.168.30.1 255.255.255.0
RT-0(config-subif)#
RT-0(config-subif)#exit
RT-0(config)#ip dh
RT-0(config)#ip dhcp po
RT-0(config)#ip dhcp pool POOL-VLAN20
RT-0(dhcp-config)#ne
RT-0(dhcp-config)#network 192.168.20.0 255.255.255.0
RT-0(dhcp-config)#de
RT-0(dhcp-config)#default-router 192.168.20.1
RT-0(dhcp-config)#dns
RT-0(dhcp-config)#dns-server 192.168.10.11
RT-0(dhcp-config)#exit
RT-0(config)#ip dh
RT-0(config)#ip dhcp e
RT-0(config)#ip dhcp excluded-address 192.168.20.1 192.168.20.10
RT-0(config)#
RT-0(config)#ip dhcp pool POOL-VLAN30
RT-0(dhcp-config)#net
RT-0(dhcp-config)#network 192.168.30.0 255.255.255.0
RT-0(dhcp-config)#de
RT-0(dhcp-config)#default-router 192.168.30.1
RT-0(dhcp-config)#dns
RT-0(dhcp-config)#dns-server 192.168.10.11
RT-0(dhcp-config)#ip dh
RT-0(dhcp-config)#exit
RT-0(config)#ip dh
RT-0(config)#ip dhcp e
RT-0(config)#ip dhcp excluded-address 192.168.30.1 192.168.30.10
RT-0(config)#
- Switch>
Switch>
Switch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#int fa0/23-24
^
% Invalid input detected at '^' marker.
Switch(config)#int range fa0/23-24
Switch(config-if-range)#exit
Switch(config)#hos
Switch(config)#hostname SW-3
SW-3(config)#int range fa0/23-24
SW-3(config-if-range)#switchport mode access
SW-3(config-if-range)#switchport access vlan 40
% Access VLAN does not exist. Creating vlan 40
SW-3(config-if-range)#exit
SW-3(config)#int range fa0/1-2
SW-3(config-if-range)#switchport mode trunk
SW-3(config-if-range)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/2, changed state to up
SW-3(config-if-range)#vlan 50
SW-3(config-vlan)#exit
SW-3(config)#
SW-3(config)#int g0/2
SW-3(config-if)#switchport mode trunk
SW-3(config-if)# - itch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hos
Switch(config)#hostname SW-4
SW-4(config)#int ra
SW-4(config)#int range fa0/23-24
SW-4(config-if-range)#switchport mode access
SW-4(config-if-range)#switchport access vlan 50
SW-4(config-if-range)#exit
SW-4(config)#int range fa0/1-2
SW-4(config-if-range)#switchport mode trunk
Switch>
Switch>
Switch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#hos
Switch(config)#hostname SW-5
SW-5(config)#int ra
SW-5(config)#int range fa0/23-24
SW-5(config-if-range)#switchport mode access
SW-5(config-if-range)#switchport access vlan 60
% Access VLAN does not exist. Creating vlan 60
SW-5(config-if-range)#
- Switch>ena
Switch>enable
Switch#ena
Switch#enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#ho
Switch(config)#hostname MLS-0
MLS-0(config)#int fa0/1
MLS-0(config-if)#switchport mode access
MLS-0(config-if)#switchport access vlan 40
% Access VLAN does not exist. Creating vlan 40
MLS-0(config-if)#int range
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on FastEthernet0/1 (40), with Switch FastEthernet0/1 (1).
^
% Invalid input detected at '^' marker.
MLS-0(config-if)#int range fa
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on FastEthernet0/1 (40), with Switch FastEthernet0/1 (1).
^
% Invalid input detected at '^' marker.
MLS-0(config-if)#
MLS-0(config-if)#
MLS-0(config-if)#
MLS-0(config-if)#no switchport access vlan 40
MLS-0(config-if)#no switchport mode access
Command rejected: An interface must be configured to the Access or Trunk modes to be configured to NoNegotiate.
MLS-0(config-if)#no switchport mode access %SPANTREE-2-RECV_PVID_ERR: Received 802.1Q BPDU on non trunk GigabitEthernet0/2 VLAN1.
%SPANTREE-2-BLOCK_PVID_LOCAL: Blocking GigabitEthernet0/2 on VLAN0001. Inconsistent port type.
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/2, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/2, changed state to up
Command rejected: An interface must be configured to the Access or Trunk modes to be configured to NoNegotiate.
MLS-0(config-if)#
MLS-0(config-if)#hos
MLS-0(config-if)#exit
MLS-0(config)#hos
MLS-0(config)#
MLS-0(config)#
MLS-0(config)#
MLS-0(config)#int g0/2
MLS-0(config-if)#switchport mode trunk
Command rejected: An interface whose trunk encapsulation is "Auto" can not be configured to "trunk" mode.
MLS-0(config-if)#sw
MLS-0(config-if)#switchport e
MLS-0(config-if)#switchport t
MLS-0(config-if)#switchport trunk e
MLS-0(config-if)#switchport trunk encapsulation d
MLS-0(config-if)#switchport trunk encapsulation dot1q
MLS-0(config-if)#switchport mode trunk
MLS-0(config-if)#vlan 40
MLS-0(config-vlan)#vlan 50
MLS-0(config-vlan)#exit
MLS-0(config)#ip routing
MLS-0(config)#int vlan 40
MLS-0(config-if)#
%LINK-5-CHANGED: Interface Vlan40, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan40, changed state to up
MLS-0(config-if)#ip ad
MLS-0(config-if)#ip address 192.168.40.1 255.255.255.0
MLS-0(config-if)#exit
MLS-0(config)#int vl
MLS-0(config)#int vlan 50
MLS-0(config-if)#
%LINK-5-CHANGED: Interface Vlan50, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan50, changed state to up
MLS-0(config-if)#ip ad
MLS-0(config-if)#ip address 192.168.50.1 255.255.255.0
MLS-0(config-if)#
MLS-0(config)#int fa0/1
MLS-0(config-if)#ip ad
MLS-0(config-if)#ip add
MLS-0(config-if)#no sw
MLS-0(config-if)#no switchport
MLS-0(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up
MLS-0(config-if)#ip ad
MLS-0(config-if)#ip address 192.168.60.1 255.255.255.0 - MLS-0(config)#int g0/1
MLS-0(config-if)#no sw
MLS-0(config-if)#no switchport
MLS-0(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up
MLS-0(config-if)#ip ad
MLS-0(config-if)#ip address 192.168.100.2 255.255.255.0
MLS-0(config-if)#
MLS-0(config-if)#exit
MLS-0(config)#ip route 192.168.10.0 255.255.255.0 192.168.100.1
MLS-0(config)#
MLS-0(config)#int vlan 40
MLS-0(config-if)#ip hel
MLS-0(config-if)#ip helper-ad
MLS-0(config-if)#ip helper-address 192.168.10.10
MLS-0(config-if)#int vlan 50
MLS-0(config-if)#ip help
MLS-0(config-if)#ip helper-address 192.168.10.10
MLS-0(config-if)#int fa0/1
MLS-0(config-if)#ip hel
MLS-0(config-if)#ip helpe
MLS-0(config-if)#ip helper-address 192.168.10.10
MLS-0(config-if)#
6. Configurasi RT-0
- RT-0>ena
RT-0>enable
RT-0#conf t
Enter configuration commands, one per line. End with CNTL/Z.
RT-0(config)#int g0/0/1
RT-0(config-if)#ip ad
RT-0(config-if)#ip address 192.168.100.1 255.255.255.0
RT-0(config-if)#no sh
RT-0(config-if)#no shutdown
RT-0(config-if)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0/1, changed state to up
RT-0(config-if)#
RT-0(config-if)#exit
RT-0(config)#ip route 192.168.40.0 255.255.255.0 192.168.100.2
RT-0(config)#ip route 192.168.50.0 255.255.255.0 192.168.100.2
RT-0(config)#ip route 192.168.60.0 255.255.255.0 192.168.100.2
RT-0(config)#
RT-0>enable
RT-0#conf t
Enter configuration commands, one per line. End with CNTL/Z.
RT-0(config)#
RT-0(config)#ip host mls-0.seno.com 192.168.100.2
RT-0(config)#ip host mls-0_vlan 60.seno.com 192.168.60.1
^
% Invalid input detected at '^' marker.
RT-0(config)#ip host mls-0_vlan60.seno.com 192.168.60.1
RT-0(config)#ip host mls-0_vlan40.seno.com 192.168.40.1
RT-0(config)#ip host mls-0_vlan50.seno.com 192.168.50.1
RT-0(config)#no ip host mls-0_vlan50.seno.com 192.168.50.1
RT-0(config)#no ip host mls-0_vlan40.seno.com 192.168.40.1
RT-0(config)#no ip host mls-0_vlan60.seno.com 192.168.60.1
RT-0(config)#no ip host mls-0.seno.com 192.168.100.2
RT-0(config)#ip dom
RT-0(config)#ip domain-na
RT-0(config)#ip domain-name seno.com - RT-0(config)#ip name-server 192.168.10.11
RT-0(config)#ip domain
RT-0(config)#ip domain-look
RT-0(config)#ip domain-lookup
RT-0(config)#
EmoticonEmoticon