Konfigurasi HSRP di Cisco Packet Tracer
Halo sobat pada kesempatan ini saya akan memberikan langkah-langkah konfigurasi HSRP yang lumayan ribet :D, ya semoga aja bisa paham dengan penjelasan saya :D, Yuk langsung saja ke TKPnya.
A. PENGERTIAN
HSRP (Hot Standby Redundancy Protocol) salah satu protokol FHRP (First Hop Redundancy Protocol). HSRP adalah bawaan cisco dan hanya bisa berjalan apa bila router di network juga menggunakan router cisco. jadi HSRP adalah cisco proprietary.pada HSRP paket hello menggunakan UDP port 1985 (haaa kayak tahun lahir) dengan ip 224.0.0.2 pada HSRP versi 1 dan ip 224.0.0.102 pada HSRP versi 2 (IOS 12.2 (46)SE keatas sudah pakai versi 2.
B. LATAR BELAKANG
C. ALAT DAN BAHAN
- Laptop
- Aplikasi Cisco Packet Tracer
D.MAKSUD DAN TUJUAN
Tujuan HSRP standby router untuk memonitor status operasional pada HSRP group dan cepat bertanggung jawab meneruskan paket jika active router tidak beroprasi . Active dan standby router saling mengirimkkan hello message untuk menginformasikan di dalam group menggenai peran dan status nya.
E. TAHAPAN PELAKSANAAN KEGIATAN
1. Sebelumnya siapkan topologi seperti gambar dibawah ini untuk memulai konfigurasi HSRP.
2. Sesuai gambar diatas kita akan mengkonfigurasikan penggunaan HSRP dengan langkah-langkah sebagai berikut :
- Konfigurasi STP port fast di switch
- Konfigurasi OSPF routing dan verifikasi di seiap router
- Konfigurasi HSRP and verifikasi di router R-100 dan R-200
- Konfigurasi Ethernet interface di PC0 dan server0 dan test failover
3. Kemudian konfigurasi STP Port fast di switch
Switch>en
Switch#conf t
SWX#config)#hostname SWX
SWX#config)#spanning-tree mode rapid-pvst
SWX#config)#spanning-tree portfast default
Switch#conf t
SWX#config)#hostname SWX
SWX#config)#spanning-tree mode rapid-pvst
SWX#config)#spanning-tree portfast default
4. Konfigurasi IP address pada setiap router dan OSPF routing di R-100 R-200 dan R-OUT.
Konfigurasi Router R-100
Router>en
Router#conf t
Router(config)#hostname R-100
R-100(config)#interface gi0/0
R-100(config-if)#ip address 10.0.20.2 255.255.255.0
R-100(config-if)#no shut
R-100(config-if)#interface gi0/1
R-100(config-if)#ip address 192.168.10.100 255.255.255.0
R-100(config-if)#no shut
R-100(config-if)#exit
R-100(config)#router ospf 100
R-100(config-router)#network 192.168.10.0 0.0.0.255 area 0
R-100(config-router)#network 10.0.20.0 0.0.0.255 area 0
R-100(config-router)#end
Router#conf t
Router(config)#hostname R-100
R-100(config)#interface gi0/0
R-100(config-if)#ip address 10.0.20.2 255.255.255.0
R-100(config-if)#no shut
R-100(config-if)#interface gi0/1
R-100(config-if)#ip address 192.168.10.100 255.255.255.0
R-100(config-if)#no shut
R-100(config-if)#exit
R-100(config)#router ospf 100
R-100(config-router)#network 192.168.10.0 0.0.0.255 area 0
R-100(config-router)#network 10.0.20.0 0.0.0.255 area 0
R-100(config-router)#end
Konfigurasi Router R-200
Router>en
Router#conf t
Router(config)#hostname R-200
R-200(config)#interface gi0/0
R-200(config-if)#ip address 10.0.10.2 255.255.255.0
R-200(config-if)#no shut
R-200(config-if)#interface gi0/1
R-200(config-if)#ip address 192.168.10.200 255.255.255.0
R-200(config-if)#no shut
R-200(config-if)#exit
R-200(config)#router ospf 100
R-200(config-router)#network 192.168.10.0 0.0.0.255 area 0
R-200(config-router)#network 10.0.10.0 0.0.0.255 area 0
R-200(config-router)#end
Router#conf t
Router(config)#hostname R-200
R-200(config)#interface gi0/0
R-200(config-if)#ip address 10.0.10.2 255.255.255.0
R-200(config-if)#no shut
R-200(config-if)#interface gi0/1
R-200(config-if)#ip address 192.168.10.200 255.255.255.0
R-200(config-if)#no shut
R-200(config-if)#exit
R-200(config)#router ospf 100
R-200(config-router)#network 192.168.10.0 0.0.0.255 area 0
R-200(config-router)#network 10.0.10.0 0.0.0.255 area 0
R-200(config-router)#end
Konfigurasi Router R-Out
Router>en
Router#conf t
Router(config)#hostname R-OUT
R-OUT(config)#int gi0/0
R-OUT(config-if)#ip address 10.0.10.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#int gi0/1
R-OUT(config-if)#ip address 10.0.20.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#int gi0/2
R-OUT(config-if)#ip add 172.16.10.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#exit
R-OUT(config)#router ospf 100
R-OUT(config-router)#network 10.1.20.0 0.0.0.255 area 0
R-OUT(config-router)#network 10.1.10.0 0.0.0.255 area 0
R-OUT(config-router)#default-information originate
R-OUT(config-router)#exit
R-OUT(config)#ip route 0.0.0.0 0.0.0.0 Gi0/2
Router#conf t
Router(config)#hostname R-OUT
R-OUT(config)#int gi0/0
R-OUT(config-if)#ip address 10.0.10.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#int gi0/1
R-OUT(config-if)#ip address 10.0.20.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#int gi0/2
R-OUT(config-if)#ip add 172.16.10.1 255.255.255.0
R-OUT(config-if)#no shut
R-OUT(config-if)#exit
R-OUT(config)#router ospf 100
R-OUT(config-router)#network 10.1.20.0 0.0.0.255 area 0
R-OUT(config-router)#network 10.1.10.0 0.0.0.255 area 0
R-OUT(config-router)#default-information originate
R-OUT(config-router)#exit
R-OUT(config)#ip route 0.0.0.0 0.0.0.0 Gi0/2
5. Selanjutnya verifikasi ip route di router R-100 dan R-200 jika sudah aktif seharusnya di setiap router tersebut akan ada default router(type O*E2).
R-200#show ip route
Codes: L - local, C - connected, S - static, 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 10.0.20.1 to network 0.0.0.0
10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O 10.0.10.0/24 [110/2] via 10.0.20.1, 00:08:19, GigabitEthernet0/0
C 10.0.20.0/24 is directly connected, GigabitEthernet0/0
L 10.0.20.2/32 is directly connected, GigabitEthernet0/0
192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.10.0/24 is directly connected, GigabitEthernet0/1
L 192.168.10.200/32 is directly connected, GigabitEthernet0/1
O*E2 0.0.0.0/0 [110/1] via 10.0.20.1, 00:05:50, GigabitEthernet0/0
Codes: L - local, C - connected, S - static, 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 10.0.20.1 to network 0.0.0.0
10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
O 10.0.10.0/24 [110/2] via 10.0.20.1, 00:08:19, GigabitEthernet0/0
C 10.0.20.0/24 is directly connected, GigabitEthernet0/0
L 10.0.20.2/32 is directly connected, GigabitEthernet0/0
192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.10.0/24 is directly connected, GigabitEthernet0/1
L 192.168.10.200/32 is directly connected, GigabitEthernet0/1
O*E2 0.0.0.0/0 [110/1] via 10.0.20.1, 00:05:50, GigabitEthernet0/0
Nb : Jika pada saat show ip route tidak muncul seperti diatas bisa di cek lagi mungkin ada konfigurasi yang kurang atau salah
6. Sekarang kita masuk ke konfigurasi HSRP group 1 di R-100 dan R-200 menggunakan 192.168.10.100 sebagai standby virtual IP address. R-100 akan dikonfigurasi sebagai HSRP active default-gateway dan R-200 akan dikonfigurasi sebagai standby preemption akan dikonfigurasikan di kedua router.
Mengaktifkan HSRP di R-100
Mengaktifkan HSRP di R-100
R-100(config)#interface gi0/1
R-100(config-if)#standby 1 ip 192.168.10.50
R-100(config-if)#standby 1 preempt
R-100(config-if)#standby 1 ip 192.168.10.50
R-100(config-if)#standby 1 preempt
Mengaktifkan HSRP di R-200
R-200(config)#interface gi0/1
R-200(config-if)#standby 1 ip 192.168.10.50
R-200(config-if)#standby 1 priority 95
R-200(config-if)#standby 1 preempt
R-200(config-if)#standby 1 ip 192.168.10.50
R-200(config-if)#standby 1 priority 95
R-200(config-if)#standby 1 preempt
7. Pada konfigurasi diatas ada preempt hal ini memastikan bila R-100 down lalu setelah beberapa saat up kembali maka jalur data akan dikembalikan melewati R-100 kembali.
R-100#show standby
GigabitEthernet0/1 - Group 1 (version 2)
State is Active
7 state changes, last state change 01:17:39
Virtual IP address is 192.168.10.50
Active virtual MAC address is 0000.0C9F.F001
Local virtual MAC address is 0000.0C9F.F001 (v2 default)
Hello time 3 sec, hold time 10 sec
Next hello sent in 0.209 secs
Preemption enabled
Active router is local
Standby router is 192.168.10.200
Priority 100 (default 100)
Group name is hsrp-Gig0/1-1 (default)
R-100#sh standby brief
P indicates configured to preempt.
|
Interface Grp Pri P State Active Standby Virtual IP
Gig0/1 1 100 P Active local 192.168.10.200 192.168.10.50
R-200#show standby brief
P indicates configured to preempt.
|
Interface Grp Pri P State Active Standby Virtual IP
Gig0/1 1 95 P Standby 192.168.10.100 local 192.168.10.50
GigabitEthernet0/1 - Group 1 (version 2)
State is Active
7 state changes, last state change 01:17:39
Virtual IP address is 192.168.10.50
Active virtual MAC address is 0000.0C9F.F001
Local virtual MAC address is 0000.0C9F.F001 (v2 default)
Hello time 3 sec, hold time 10 sec
Next hello sent in 0.209 secs
Preemption enabled
Active router is local
Standby router is 192.168.10.200
Priority 100 (default 100)
Group name is hsrp-Gig0/1-1 (default)
R-100#sh standby brief
P indicates configured to preempt.
|
Interface Grp Pri P State Active Standby Virtual IP
Gig0/1 1 100 P Active local 192.168.10.200 192.168.10.50
R-200#show standby brief
P indicates configured to preempt.
|
Interface Grp Pri P State Active Standby Virtual IP
Gig0/1 1 95 P Standby 192.168.10.100 local 192.168.10.50
Ppada step ini sudah 80% komplit jika saat verifikasi HSRP tidak seperti diatas coba di cek lagi mungkin ada salah atau kurang pada konfigurasi.
8. Konfigurasi Ethernet interface pada host PC dan tes fungsi HSRP failover dengan mengkonfigurasi terlebih dahulu ip address, netmask dan default gateway PC0 dan server0 sesuai table diatas.
Tes konektivitas dengan ping dari PC0 ke server0
8. Konfigurasi Ethernet interface pada host PC dan tes fungsi HSRP failover dengan mengkonfigurasi terlebih dahulu ip address, netmask dan default gateway PC0 dan server0 sesuai table diatas.
Tes konektivitas dengan ping dari PC0 ke server0
PC>ping 172.16.10.2
Pinging 172.16.10.2 with 32 bytes of data:
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=18ms TTL=126
Reply from 172.16.10.2: bytes=32 time=10ms TTL=126
Reply from 172.16.10.2: bytes=32 time=16ms TTL=126
Ping statistics for 172.16.10.2:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 1ms, Maximum = 18ms, Average = 11ms
Pinging 172.16.10.2 with 32 bytes of data:
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=18ms TTL=126
Reply from 172.16.10.2: bytes=32 time=10ms TTL=126
Reply from 172.16.10.2: bytes=32 time=16ms TTL=126
Ping statistics for 172.16.10.2:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 1ms, Maximum = 18ms, Average = 11ms
Tes konektivitas menggunakan tracert
PC>tracert 172.16.10.2
Tracing route to 172.16.10.2 over a maximum of 30 hops:
1 18 ms 0 ms 0 ms 192.168.10.100
2 12 ms 12 ms 12 ms 10.0.10.1
3 15 ms 11 ms 12 ms 172.16.10.2
Trace complete.
Tracing route to 172.16.10.2 over a maximum of 30 hops:
1 18 ms 0 ms 0 ms 192.168.10.100
2 12 ms 12 ms 12 ms 10.0.10.1
3 15 ms 11 ms 12 ms 172.16.10.2
Trace complete.
9. Tes HSRP dengan ping dari PCO ke server 0 menggunakan ping –t 172.16.10.2 Setelah ping berjalan berikutnya adalah kita matikan interface g0/1 pada router R-100.
R-100#conf t
R-100(config)#int gi0/1
R-100(config-if)#shutdown
%HSRP-6-STATECHANGE: GigabitEthernet0/1 Grp 1 state Active -> Init
%LINK-5-CHANGED: Interface GigabitEthernet0/1, changed state to administratively down
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to down
00:19:08: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.200 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Interface down or detached
R-100(config)#int gi0/1
R-100(config-if)#shutdown
%HSRP-6-STATECHANGE: GigabitEthernet0/1 Grp 1 state Active -> Init
%LINK-5-CHANGED: Interface GigabitEthernet0/1, changed state to administratively down
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to down
00:19:08: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.200 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Interface down or detached
10. Lihat di console R-200 notifikasi dari standby ke active.
%HSRP-6-STATECHANGE: GigabitEthernet0/1 Grp 1 state Standby -> Active
00:19:40: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.100 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Dead timer expired
00:19:40: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.100 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Interface down or detached
00:19:40: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.100 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Dead timer expired
00:19:40: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.100 on GigabitEthernet0/1 from FULL to DOWN, Neighbor Down: Interface down or detached
11. Hasil ping di PC pun sempat RTO sebentar lalu reply kembali.
Reply from 172.16.10.2: bytes=32 time=0ms TTL=126
Reply from 172.16.10.2: bytes=32 time=0ms TTL=126
Reply from 172.16.10.2: bytes=32 time=0ms TTL=126
Request timed out.
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=0ms TTL=126
Reply from 172.16.10.2: bytes=32 time=0ms TTL=126
Request timed out.
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
Reply from 172.16.10.2: bytes=32 time=1ms TTL=126
12. Selanjutnya adalah mengembalikan keadaan seperti semula dengan menghidupkan interface g0/1 di router R-100.
R-100(config-if)#no shutdown
%LINK-5-CHANGED: Interface GigabitEthernet0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up
%HSRP-6-STATECHANGE: GigabitEthernet0/1 Grp 1 state Standby -> Active
%LINK-5-CHANGED: Interface GigabitEthernet0/1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up
%HSRP-6-STATECHANGE: GigabitEthernet0/1 Grp 1 state Standby -> Active
F. REFERENSI
http://www.ngonfig.com/configuration-172-cisco-router--hot-standby-router-protocol-hsrp.html
G. KESIMPULAN
0 Comments for "Konfigurasi HSRP di Cisco Packet Tracer - BLC TELKOM"