Vinay kumar madhadi l.jpg
This presentation is the property of its rightful owner.
Sponsored Links
1 / 27

LEADER ELECTION PowerPoint PPT Presentation

  • Uploaded on
  • Presentation posted in: General

Vinay Kumar Madhadi. CSC-8320. LEADER ELECTION. 09/23/2009. Outline. Part 1 : Leader Election? Part 2 : Different Design Topologies Algorithms Used-Bully, Ring , Invitation Recent Studies Part 3 : Future work. Part 1: What is Leader Election?.

Download Presentation


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript

Vinay kumar madhadi l.jpg

Vinay Kumar Madhadi




Outline l.jpg


  • Part 1 : Leader Election?

  • Part 2 : Different Design Topologies

    Algorithms Used-Bully, Ring , Invitation

    Recent Studies

  • Part 3 : Future work

Part 1 what is leader election l.jpg

Part 1: What is Leader Election?

  • In distributed computing, leader election is the process of designating a single process as the organizer, coordinator, initiator or sequencer of some task distributed among several computers (nodes).

    (Chow et al, 1997)

  • Leader election is the process of determining a process as the manager of some task distributed among several processes (computers).

    (Garcia, Molina 1982)

Why is leader election required l.jpg

Why is Leader Election Required?

  • The existence of a centralized controller greatly simplifies process synchronization.

  • However, if the central controller breaks down, the service availability can be limited. The problem can be avoided if a new controller (leader) can be chosen.

  • Different Algorithms would be employed to successfully elect the leader.

Criteria for leader election l.jpg

Criteria for Leader Election?

  • 1: Extrema finding - Leader election is based on global priority. Here, every node is characterized by fixed evaluation value.

  • 2: Preference-based - Processes in the group can vote for leader based on node’s preference (locality, reliability, estimation).

    (Chow et al , 1997)

    The main concern is usually the fast and successful completion of election process.

Leader election vs mutual exclusion l.jpg

Leader Election VS Mutual Exclusion

Leader Election

Mutual Exclusion

  • Process may yield to others and execute normally as long as leader is selected.

  • Concerned with fast and successful termination of election process.

  • Result of leader election must be known to other processes.

  • Process competes until it succeeds.

  • Must ensure that no process is starved.

  • Does not care which process is running in critical section.

Leader election vs synchronization l.jpg

Leader election VS Synchronization

Leader Election


  • In synchronization, the non-token holders only need to know that they do not hold the token.

  • Synchronization algorithms are designed to work well in absence of failures.

  • In election, all participants must know who owns the token(i.e. who is the leader).

  • Election algorithms are performed only if failure occurs.

Part 2 design topologies l.jpg

Part 2: Design Topologies

There are three design topologies employed


  • Complete Topology

  • Local Ring Topology

  • Tree Topology

Complete topology l.jpg

Complete Topology

  • Each process in the group can reach any other process in the same group in one message hop.

  • Assumptions taken

    • All process ids are unique and known to every process

    • Communication network is reliable and only the communicating processes may fail.

    • Process takes a known finite amount of time to handle a message, in other words, the process is considered as crashed if it doesn’t respond within specified time-out period

  • The Bully Algorithm is based on the assumptions of complete topology.

Bully algorithm l.jpg

Bully Algorithm:

  • This is an extrema-finding algorithm.

  • In this algorithm, the highest-numbered process becomes coordinator. Thus the biggest guy in town always wins, hence the name “Bully Algorithm.”


    • P sends an ELECTION message to all processes with higher numbers.

    • If no one responds, P wins the election and becomes coordinator.

    • If any of the higher ups responds, then the latter becomes the coordinator.

Bully algorithm11 l.jpg

Bully Algorithm:

  • (a) Process 4 holds an election.

  • (b) Processes 5 and 6 respond telling 4 to stop.

  • (c)Now 5 and 6 each hold an election

Bully algorithm12 l.jpg

Bully Algorithm:

  • (d) Process 6 responds to the call from 5 and tells it to stop.

  • (e) Process 6 wins and tells everyone.

Local ring topology l.jpg

Local Ring Topology:

  • This topology is easy to construct and it offers a unique property that a message initiated by any node will return to the node.

  • The Ring Algorithm employs this topology.

Ring algorithm l.jpg

Ring Algorithm:

  • Initiation:

    • A process sends an ELECTION message to its successor (or next alive process) with its ID

    • Each process adds its own ID and forwards the ELECTION message

  • Leader Election:

    • Message comes back to initiator

    • Initiator announces the winner by sending another message around the ring

Ring algorithm15 l.jpg

Ring Algorithm:

  • (a) Process 4 sends the election message to it successor with its ID.

  • (b) Each process adds its own ID and then forwards the message to the next process.

Ring algorithm16 l.jpg

Ring Algorithm:

  • (c) Message is sent back to the initiator which is 4.

  • (b) Initiator announces the winner by sending another message around the ring.

Tree topology l.jpg

Tree Topology:

  • To construct a logical ring structure is easy if the underlying network supports broadcast facilities.

  • A tree is used as representative topological structure.

  • Each node is considered an autonomous entity that exchanges messages with adjacent nodes

  • A minimum-weight spanning tree(MST) is used for leader election in tree topology

Invitation algorithm l.jpg

Invitation Algorithm:

  • This Algorithm is basically designed for asynchronous systems.

  • It also tends to eliminate the possible drawbacks of Bully’s algorithm.


  • The invitation algorithm classifies nodes into groups and elects coordinator for every group.

  • Each node in a group periodically checks whether the leader is alive or not, by sending a message to the leader and waits for reply.

  • If the node does not reply within a timeout period, the node invokes a Recovery procedure.

Invitation algorithm19 l.jpg

Invitation Algorithm:

  • The recovery procedure puts node i into a singleton group with node i as the leader.

  • Periodically, each leader i calls a check procedure, which sends messages to every other node asking whether that node is a leader.

  • If many nodes responds that it is a leader, node i pauses for some time and then calls for a merge procedure.

  • Merge procedure sends message to all the leaders, inviting them to join a new group with the inviting node as leader.

  • Example :Group communication system in Amoeba uses Invitation Algorithm to reconfigure a group after a node crashes.( kaashoek, Tanenbaum, 1991)

Part 2 recent studies l.jpg

Part 2: Recent Studies


  • Divided Ring Algorithm is proposed which is a potential replacement to the ring algorithm. This process involves dividing the rings into sub-groups.

    Advantage: Overall latency is reduced.

    (Vojdani, Taj, 2009)

    2. Conventional algorithms in distributed systems present particular methods to resolve any leader crash. A new method based on electing a leader and assistant was introduced. If the leader crashes, the assistant takes care of the leader's responsibilities.

    (Zargarnataj, 2007)

Recent studies leader election in ad hoc networks sefa l.jpg

Recent Studies:Leader election in Ad-Hoc Networks-SEFA

  • Leader Election is now being implemented in Ad-Hoc networks as well. Most of the leader election algorithms for mobile ad hoc networks elect a “random” leader and hence are not extrema-finding

  • SEFA(Secure Extrema Finding Algorithm) is a round-based hierarchy-building approach which is considered a secure problem. This algorithm designed for Ad-Hoc networks handles frequent topology changes and dynamic nature of mobile networks too.

    (Vasudevan, Kurose, Towsley, 2003)

Secure election finding algorithm sefa l.jpg

Secure Election Finding Algorithm(SEFA)

  • SEFA is an extrema-finding algorithm in which all nodes use a Common Election Algorithm (CEA) to determine their rank

  • Decision factors might include node identity, battery life, or level of trust…etc

  • Larger the CEA value, the more “desirable” the node is a leader

  • Good reviews regarding the same can be found in (G. Tel. 2000) and (N.Lynch 1996)

Part 3 future work l.jpg

Part 3: Future Work

  • The bully and ring algorithms are employed for wired networks and the invitation algorithm for a wireless network. An algorithm in which nodes are divided into peers and super-peers is currently being employed for Very Large Scale Systems. This algorithm is not very well developed. Research is being done to develop algorithms which can be implemented for Very large Scale networks.

    (Tanenbaum, Steen, 2007)

  • An extension of the divided ring algorithm may be proposed which considers not only the latency but also the number of rings

Future work contd l.jpg

Future Work contd.

  • The development of one unified algorithm which can work with both the synchronous and asynchronous systems can be expected in the near future.

  • Research has to be done to develop new leader election techniques for Ad-Hoc Networks

References l.jpg


MehdiVojdani, K. Yaser Taj, DR: Divided Ring leader Election Algorithm ( July 2009)

Tanenbaum, S., Steen, M.V.: DISTRIBUTED SYSTEMS: Principles and Paradigms, p.2e. Prentice Hall, Inc, Englewood Cliffs (2007)

Zargarnataj, M.: New Election Algorithm based on Assistant in Distributed Systems. In: AICCSA 2007, May 2007, pp. 324–331 (2007)

Vasudevan, S., DeCleene, B., Immerman, N., Kurose, J., Towsley, D.: Leader Election Algorithms for Wireless Ad Hoc Networks. In: DARPA Information Survivability Conference and Exposition, April 2003, pp. 261–272 (2003)

Distributed Systems principles and paradigms by Andrew S. Tanenbaum, Maarten van Steen, 2002.

Stoller, S.D.: Leader Election in Asynchronous Distributed Systems. IEEE Transactions on Computers, 283–284 (March 2000)

References26 l.jpg


  • G. Tel. Introduction to Distributed Algorithms. Cambridge University Press Second Edition, 2000.

  • Distributed Operating Systems & Algorithms, Randy Chow and Theodore Johnson, Addison Wesley, 1997.

  • M.F. Kaashoek and A.S. Tanenbaum, “Group Communication in the Amoeba Distributed Operating System,” Proc. IEEE 11th Int'l Conf. Distributed Computing Systems (ICDCS), pp. 222-230, 1991.

  • H. Garcia-Molina. Elections in a distributed computing system. IEEE Transactions on Computers, C-31(1):47-59, January 1982.

Thank you l.jpg


  • Login