cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
22914
Views
21
Helpful
8
Replies

Understanding standby preempt

bornno1984
Level 1
Level 1

For example 2 routers,

Router A

ip address 10.10.10.2 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 preempt
standby 1 priority 110

Router B

ip address 10.10.10.3 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 priority 100

If rtr A fails and B becomes active, will rtr A become active again if its back?

Am i right to say that preempt is only required on the higher priority rtrs and not required on the lowest priority router if there are more than 2 rtrs.

Or does all rtrs require preempt in order for highest priority rtr to become active again when its back?

2 Accepted Solutions

Accepted Solutions

Scenario A

No preempt on both routers.

Router A fails and router B takes over active role. But when router A is up, Router B remains active because there is no preempt for both.

Scenario B

Preempt on Router A only.

Router A fails and router B takes over active role. When router A goes up, Router A will take over active role because it has preempt.

Router A

ip address 10.10.10.2 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 preempt
standby 1 priority 110

Router B

ip address 10.10.10.3 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 priority 100

Current State-

A#sh standby

FastEthernet0/0 - Group 1

  State is Active

    2 state changes, last state change 00:04:13

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 1.624 secs

  Preemption enabled

  Active router is local

  Standby router is 10.10.10.3, priority 100 (expires in 8.740 sec)

  Priority 110 (configured 110)

  Group name is "hsrp-Fa0/0-1" (default)

Now see when RTR A Fails-

B#sh standby

FastEthernet0/0 - Group 1

  State is Active

    2 state changes, last state change 00:00:41

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 0.752 secs

  Preemption disabled

  Active router is local

  Standby router is unknown

  Priority 100 (default 100)

  Group name is "hsrp-Fa0/0-1" (default)

Lets bring A back -

A#sh standby

FastEthernet0/0 - Group 1

  State is Active

    4 state changes, last state change 00:00:09

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 2.684 secs

  Preemption enabled

  Active router is local

  Standby router is unknown

  Priority 110 (configured 110)

  Group name is "hsrp-Fa0/0-1" (default)

Senario C

Both routers with preempt.

Works the same as scenario B.

Question to your answer Preempt is only required on one router.So in both the cases router A will take role of active router when it fails then only router B will become active.

Thanks

Ajay

View solution in original post

John

As I read your posts you consistently say that if the active HSRP router goes down but what this link is talking about is a situation where the router does not go down but lowers its priority. And that is a significantly different situation than when the router goes down.

For the situation described by the original poster (2 routers, no tracking configured) then yes it is accurate to say that preempt is required only on router A. If router A has the higher priority and if it is configured with preempt then any time that router A is up then it will be the active router. There is not need for preempt on router B .

HTH

Rick

HTH

Rick

View solution in original post

8 Replies 8

JohnTylerPearce
Level 7
Level 7

In your example, RA has a priority of 110 while B has a priority of 100 (You don't need to configure priority 100 it is the default priority for HSRP). Well, you can it just isn't really required. With this configuration you will have a problem. If RA goes down lets say, it will decrement its priorit by 10 (default), which will make it's priority 100. Both priorities will then be the same (and I think the highest IP address configured will become active) to be honest I forgot that part. But what I would do is give RA a priority of 105, and give RB the preempt command. THis will cause RA to decrement by 10 (default) which would be 95, and with the preempt command on RB, RB would become active. Now once RA was back up it would have a priority of 105 and with the preempt command would change from Standby to Active. You need the preempt command otherwise, if it has a higher priority it will not become active.

Hi thanks for the response,

But do i need the preempt on rtr B? is it necessary?

For my understanding, preempt is only required for higher priority routers and not the last resort router.

Well, if your Active HSRP router goes down, and your other router doesn't have preempt configured, it will not take over as Active router. Preempt allows a router to take over as Active if it has a higher priority configured, but that's only if you configure the 'standby preempt' command.

Sorry John, i beg to differ.

But even without preempt, the standby router will still take over the active role. Its when the higher priority router with preempt that will take over the active role when both routers are up.

Scenario A

No preempt on both routers.

Router A fails and router B takes over active role. But when router A is up, Router B remains active because there is no preempt for both.

Scenario B

Preempt on Router A only.

Router A fails and router B takes over active role. When router A goes up, Router A will take over active role because it has preempt.

Senario C

Both routers with preempt.

Works the same as scenario B.

So my question is whether is there a difference for scenario B and C?

This should explain what I was talking about.

Notice in the output that the HSRP priority of R1 is reduced by 10—to 95. This change makes the R2 priority of 100 higher. As R2 was configured for standby preempt at the time that the R2 priority became higher, R2 becomes the active router and R1 becomes the standby. Now, if the R1 serial 0 interface comes back up, the R1 priority is 105, again. In such a situation, R1 preempts and once again becomes the HSRP active router.

http://www.cisco.com/en/US/tech/tk648/tk362/technologies_tech_note09186a0080094e8c.shtml

Scenario A

No preempt on both routers.

Router A fails and router B takes over active role. But when router A is up, Router B remains active because there is no preempt for both.

Scenario B

Preempt on Router A only.

Router A fails and router B takes over active role. When router A goes up, Router A will take over active role because it has preempt.

Router A

ip address 10.10.10.2 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 preempt
standby 1 priority 110

Router B

ip address 10.10.10.3 255.255.255.0
standby 1 ip 10.10.10.1
standby 1 priority 100

Current State-

A#sh standby

FastEthernet0/0 - Group 1

  State is Active

    2 state changes, last state change 00:04:13

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 1.624 secs

  Preemption enabled

  Active router is local

  Standby router is 10.10.10.3, priority 100 (expires in 8.740 sec)

  Priority 110 (configured 110)

  Group name is "hsrp-Fa0/0-1" (default)

Now see when RTR A Fails-

B#sh standby

FastEthernet0/0 - Group 1

  State is Active

    2 state changes, last state change 00:00:41

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 0.752 secs

  Preemption disabled

  Active router is local

  Standby router is unknown

  Priority 100 (default 100)

  Group name is "hsrp-Fa0/0-1" (default)

Lets bring A back -

A#sh standby

FastEthernet0/0 - Group 1

  State is Active

    4 state changes, last state change 00:00:09

  Virtual IP address is 10.10.10.1

  Active virtual MAC address is 0000.0c07.ac01

    Local virtual MAC address is 0000.0c07.ac01 (v1 default)

  Hello time 3 sec, hold time 10 sec

    Next hello sent in 2.684 secs

  Preemption enabled

  Active router is local

  Standby router is unknown

  Priority 110 (configured 110)

  Group name is "hsrp-Fa0/0-1" (default)

Senario C

Both routers with preempt.

Works the same as scenario B.

Question to your answer Preempt is only required on one router.So in both the cases router A will take role of active router when it fails then only router B will become active.

Thanks

Ajay

John

As I read your posts you consistently say that if the active HSRP router goes down but what this link is talking about is a situation where the router does not go down but lowers its priority. And that is a significantly different situation than when the router goes down.

For the situation described by the original poster (2 routers, no tracking configured) then yes it is accurate to say that preempt is required only on router A. If router A has the higher priority and if it is configured with preempt then any time that router A is up then it will be the active router. There is not need for preempt on router B .

HTH

Rick

HTH

Rick

Yeah, I got a little confused

I did a little more research, and to be honest you don't really need the preempt command for basic functionality of HSRP. If the Active router goes down, and or anything else that you are tracking, and the Standby becomes Active, it will still work without the preempt except for once the Active comes back, the Standby will not give up that role, unless it goes down, and or preempt is configured on the ex-Active router. Sorry for this misinformation.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card