Election Algos Flashcards
(9 cards)
Describe a simple election algorithm
- P broadcasts its request to all processes
- Each process responds with id & current load
- P chooses least loaded process and announces to everyone
What are the 5 states a process can be in?
- Sleep
- Cand/Active
- Passive
- Lost
- Leader
An election algorithm must satisfy these 3 things:
- Terminal configuration in each computation
- Each configuration must have a leader and other active processes in state Lost
- An execution can be initialised by any process
Is an election algorithm centralised or decentralised?
Decentralised
What must precede an election?
A ‘wake-up’ call.
Describe how ‘wake-up’ method works.
- Election initiator sends wake up message to all neighbours
- Any process that receives the message will:
1. Wake up
2. Send wake up message to its neighbours.
Why does a woken up process only execute the wave algorithm after it knows all its neighbours have woken up?
No First-In First-Out communication assumed.
What construction can be used to make an election algorithm centralised?
Extinction.
Explain the principles of extinction.
- Each wave holds id of initiator
- Only one wave, the one with smallest id, survives.
- Initiator announces the process with smallest id as leader.