HSRP Redundancy
CCNA 200-301 v2.0 · Live Feb 3, 2027 (v1.1 valid through Feb 2, 2027) Cisco Packet Tracer
مقصدObjectiveObjective
اس لیب میں آپ HSRP سیکھیں گے — گیٹ وے کی redundancy۔ ایک راؤٹر گرے تو دوسرا فوراً اس کی جگہ لے، بغیر PCs کو پتا چلے۔Is lab mein aap HSRP seekhenge — gateway ki redundancy. Ek router gire to doosra foran uski jagah le, bina PCs ko pata chale.In this lab you'll learn HSRP — gateway redundancy. If one router goes down, the other takes over instantly, without the PCs noticing.
آسان مثالSimple AnalogySimple Analogy
آپ کے آفس کا مین گیٹ ایک ہے — اگر گارڈ (راؤٹر) بیمار ہو جائے تو سب باہر کھڑے رہ جاتے ہیں۔ HSRP کا مطلب دو گارڈ رکھنا: ایک active، ایک standby۔ دونوں کے پاس ایک ہی 'virtual' چابی (virtual IP) ہے۔ PCs کو صرف virtual IP پتا ہے۔ Active گارڈ گرے تو standby فوراً اس کی جگہ لے لیتا ہے — PCs کو پتا بھی نہیں چلتا۔Aapke office ka main gate ek hai — agar guard (router) beemar ho jaye to sab bahar khare reh jate hain. HSRP ka matlab do guards rakhna: ek active, ek standby. Dono ke paas ek hi 'virtual' chabi (virtual IP) hai. PCs ko sirf virtual IP pata hai. Active guard giray to standby foran uski jagah le leta hai — PCs ko pata bhi nahi chalta.Your office has one main gate — if the guard (router) falls sick, everyone is stuck outside. HSRP means keeping two guards: one active, one standby. Both share one 'virtual' key (virtual IP). The PCs only know the virtual IP. If the active guard falls, the standby takes his place instantly — the PCs never notice.
سیٹ اپLab SetupLab Setup
R1 اور R2 دونوں switch سے connected (192.168.10.0/24)۔ PC1 بھی اسی switch پر۔ Virtual IP 192.168.10.1۔ Devices: 2x Router 2911 (R1, R2), 1x Switch 2960, 1x PC۔ PC1: 192.168.10.10/24، گیٹ وے 192.168.10.1 (virtual IP — اصل راؤٹر کا IP نہیں!)۔R1 aur R2 dono switch se connected (192.168.10.0/24). PC1 bhi usi switch par. Virtual IP 192.168.10.1. Devices: 2x Router 2911 (R1, R2), 1x Switch 2960, 1x PC PC1: 192.168.10.10/24, gateway 192.168.10.1 (virtual IP — asal router ka IP nahi!).R1 and R2 are both connected to the switch (192.168.10.0/24). PC1 is on the same switch. Virtual IP is 192.168.10.1. Devices: 2x Router 2911 (R1, R2), 1x Switch 2960, 1x PC. PC1: 192.168.10.10/24, gateway 192.168.10.1 (virtual IP — not the router's real IP!).
اقداماتStepsSteps
Step 1
R1 — Active router۔ R1 کا اصل IP .2 ہے، لیکن virtual IP .1 ہے جو PCs گیٹ وے کے طور پر استعمال کریں گے۔R1 — Active router. R1 ka asal IP .2 hai, lekin virtual IP .1 hai jo PCs gateway ke tor par istemal karenge.R1 — Active router. R1's real IP is .2, but the virtual IP is .1, which the PCs will use as gateway.
enable configure terminal interface g0/0 ip address 192.168.10.2 255.255.255.0
Step 2
Priority 110 (default 100 سے زیادہ) اس لیے R1 active بنے گا۔ Preempt کا مطلب: واپس آنے پر دوبارہ active بن جاؤ۔Priority 110 (default 100 se zyada) is liye R1 active banega. Preempt ka matlab: wapas aane par dubara active ban jaoPriority 110 (higher than the default 100) makes R1 the active one. Preempt means: become active again when you return.
standby 1 ip 192.168.10.1 standby 1 priority 110 standby 1 preempt no shutdown exit
Step 3
R2 — Standby router۔ R2 پر بھی وہی virtual IP (.1)، لیکن priority default 100 — اس لیے یہ standby رہے گا۔R2 — Standby router. R2 par bhi wohi virtual IP (.1), lekin priority default 100 — is liye ye standby rahega.R2 — Standby router. Same virtual IP (.1) on R2, but with the default priority 100 — so it stays standby.
enable configure terminal interface g0/0 ip address 192.168.10.3 255.255.255.0 standby 1 ip 192.168.10.1 no shutdown exit
Step 4
جب R1 گرے گا تو R2 active بن جائے گا۔Jab R1 girega to R2 active ban jayegaWhen R1 goes down, R2 becomes active.
Step 5
Testing: PC1 سے باہر ping کرو۔ پھر R1 کا G0/0 shutdown کرو — 2-3 سیکنڈ میں R2 active بن جائے گا اور ping چلتا رہے گا۔Testing: PC1 se bahar ping karo. Phir R1 ka G0/0 shutdown karo — 2-3 second mein R2 active ban jayega aur ping chalta rahega.Testing: ping outside from PC1. Then shut down R1's G0/0 — within 2-3 seconds R2 becomes active and the ping keeps going.
Step 6
show standby brief سے state دیکھو۔show standby brief se state dekho.Check state with show standby brief.
تصدیقVerifyVerify
show standby brief سے Active/Standby state دیکھو۔ show standby سے تفصیل نکالو۔show standby brief se Active/Standby state dekho. show standby se detail nikalo.Check the Active/Standby state with show standby brief. Get details with show standby.
show standby brief show standby
خرابی دور کرناTroubleshootingTroubleshooting
⚠️ دونوں راؤٹرز Active بنے ہوئے ہیں۔Dono routers Active bane hue hain.Both routers are showing Active.
✅ دونوں راؤٹرز پر standby group number (1) اور virtual IP ایک جیسے ہونے چاہئیں۔Dono routers par standby group number (1) aur virtual IP same hone chahiye.The standby group number (1) and virtual IP must be the same on both routers.
⚠️ R1 واپس آیا لیکن Active نہیں بنا۔R1 wapas aaya lekin Active nahi bana.R1 came back but didn't become Active.
✅ Preempt کے بغیر پرانا active واپس آنے پر دوبارہ active نہیں بنتا۔ standby 1 preempt لگاؤ۔Preempt ke baghair purana active wapas aane par dobara active nahi banta. standby 1 preempt lagao.Without preempt, the old active router doesn't become active again after returning. Add standby 1 preempt.
انٹرویو سوالاتInterview Q&AInterview Q&A
❓ HSRP اور VRRP میں فرق؟HSRP aur VRRP mein farq?What's the difference between HSRP and VRRP?
HSRP Cisco کا proprietary ہے، VRRP open standard ہے۔ دونوں کا کام ایک ہے: گیٹ وے کی redundancy۔ GLBP load balancing بھی کرتا ہے۔HSRP Cisco ka proprietary hai, VRRP open standard hai. Dono ka kaam ek hai: gateway ki redundancy. GLBP load balancing bhi karta hai.HSRP is Cisco proprietary; VRRP is an open standard. Both do the same job: gateway redundancy. GLBP also does load balancing.