UniInt End User


Primary Stops Updating Heartbeat Point for less than 5 Intervals



Download 1.93 Mb.
Page74/79
Date29.09.2022
Size1.93 Mb.
#59623
1   ...   71   72   73   74   75   76   77   78   79
UniInt Interface User Manual
PI BASemAPI

Primary Stops Updating Heartbeat Point for less than 5 Intervals


This situation might occur if the primary interface copy fails to update its heartbeat point within four failover intervals due to the interface being “stuck” somewhere in the code. In this scenario, the primary copy does come back to life and updates its heartbeat before the backup has assumed control. Moreover, it is assumed that the primary has missed scans for data during the time it failed to update its heartbeat. For this reason, the backup will send the data it had queued during the time frame where the primary stopped updating its heartbeat point. This results in two periods of overlapping data. The first period covers the time when the primary initially hangs and the second period covers the interval when the primary comes alive again. The first overlap is the same as if the primary never came back to life. The additional overlap occurs between the times when the primary came back and before the backup noticed.

  • Every failover update interval, the backup interface reads the value of the heartbeat point for the primary interface and remembers the value internally.

  • If on the third update interval the value of the primary’s heartbeat point has not changed, the backup transitions into a temporary PrimaryStale state. This state allows the primary two additional failover update intervals of time to recover before the backup assumes control. If there was no recovery time for the primary, thrashing might result due to latency in the system architecture.

  • Upon entering the PrimaryStale state, the backup stops discarding queued data.

  • The backup interface remains in the PrimaryStale state for two failover update intervals waiting for the primary interface to come back to life.

  • Before two failover update intervals elapse, the primary resumes normal operation and updates its heartbeat point.

  • At the next failover update interval, the backup will see that the primary has resumed updating its heartbeat point and will transition back to the backup role.

  • When the backup exits the PrimaryStale state, it will send its queued data to the PI Server.

This scenario results in no loss of data even if the primary interface hangs between two and five intervals. If the primary hangs for less than two intervals, the backup never transitions to the PrimaryStale state and therefore never sends any queued data. This may result in missing scans for less than two intervals at a time.
A depiction of the timing chart for a scenario where the primary interface stops updating its heartbeat point for less than five intervals is shown in Figure 6, below.





Time

Action

T+0

Both interfaces are running with IF1 in the primary role.

T+2.25

Event A: IF1 stops updating its heartbeat point for any reason.

T+2.5

IF2 reads the active ID point and IF1’s heartbeat point. Both are good so IF2 discards data older than time 0.5.

T+3.5

Event B: IF2 notices that IF1’s heartbeat point has not updated. IF2 discards data older than Time 1.5.

T+4.5

IF2 notices that IF1 still has not updated its heartbeat point. IF2 stops discarding queued data.

T+5.5

IF2 notices that IF1 still has not updated its heartbeat point.

T+5.75

Event C: IF1 resumes operation. The active ID point is equal to IF1’s ID, so IF1 updates its heartbeat point and continues operating normally.

T+6.5

IF2 notices IF1 has updated its heartbeat point. IF2 will send the data it has in its queue and then return to normal backup operation.

IF1 was not collecting data from time 2.25 to time 5.75. IF2 will send the data it received from time 1.5 to time 6.5. This will lead to two periods of overlapping data: from time 1.5 to time 2.25 and from time 5.75 to time 6.5.



Figure 6: Timing chart for failover when the primary interface stops updating its heartbeat point for less than five intervals.

Download 1.93 Mb.

Share with your friends:
1   ...   71   72   73   74   75   76   77   78   79




The database is protected by copyright ©ininet.org 2024
send message

    Main page