Chapter 7 Fault Tolerance Basic Concepts Failure Models Process Design Issues Flat vs hierarchical group Group Membership Reliable Client.

Slides:



Advertisements
Similar presentations
Dr. Kalpakis CMSC621 Advanced Operating Systems Fault Tolerance.
Advertisements

Chapter 8 Fault Tolerance
Computer Science Lecture 18, page 1 CS677: Distributed OS Last Class: Fault Tolerance Basic concepts and failure models Failure masking using redundancy.
OCT Distributed Transaction1 Lecture 13: Distributed Transactions Notes adapted from Tanenbaum’s “Distributed Systems Principles and Paradigms”
CS 582 / CMPE 481 Distributed Systems Fault Tolerance.
Systems of Distributed Systems Module 2 -Distributed algorithms Teaching unit 3 – Advanced algorithms Ernesto Damiani University of Bozen Lesson 6 – Two.
Group Communications Group communication: one source process sending a message to a group of processes: Destination is a group rather than a single process.
Computer Science Lecture 17, page 1 CS677: Distributed OS Last Class: Fault Tolerance Basic concepts and failure models Failure masking using redundancy.
Fault Tolerance Chapter 7.
Distributed Systems CS Fault Tolerance- Part III Lecture 15, Oct 26, 2011 Majd F. Sakr, Mohammad Hammoud andVinay Kolar 1.
Distributed Systems CS Fault Tolerance- Part I Lecture 13, Oct 17, 2011 Majd F. Sakr, Mohammad Hammoud andVinay Kolar 1.
"Failure is not an option. It comes bundled with your system.“ (--unknown)
Fault Tolerance A partial failure occurs when a component in a distributed system fails. Conjecture: build the system in a such a way that continues to.
Distributed DBMSPage © 1998 M. Tamer Özsu & Patrick Valduriez Outline Introduction Background Distributed DBMS Architecture Distributed Database.
Last Class: Weak Consistency
1 Fault Tolerance Chapter 7. 2 Fault Tolerance An important goal in distributed systems design is to construct the system in such a way that it can automatically.
1 More on Distributed Coordination. 2 Who’s in charge? Let’s have an Election. Many algorithms require a coordinator. What happens when the coordinator.
Fault Tolerance Dealing successfully with partial failure within a Distributed System. Key technique: Redundancy.
1 ICS 214B: Transaction Processing and Distributed Data Management Distributed Database Systems.
Computer Science Lecture 16, page 1 CS677: Distributed OS Last Class:Consistency Semantics Consistency models –Data-centric consistency models –Client-centric.
Fault Tolerance Chapter 8 Part I Introduction
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved DISTRIBUTED SYSTEMS.
Distributed Commit Dr. Yingwu Zhu. Failures in a distributed system Consistency requires agreement among multiple servers – Is transaction X committed?
Real Time Multimedia Lab Fault Tolerance Chapter – 7 (Distributed Systems) Mr. Imran Rao Ms. NiuYu 22 nd November 2005.
1 Distributed Systems Fault Tolerance Chapter 8. 2 Course/Slides Credits Note: all course presentations are based on those developed by Andrew S. Tanenbaum.
Fault Tolerance. Agenda Overview Introduction to Fault Tolerance Process Resilience Reliable Client-Server communication Reliable group communication.
Chapter 19 Recovery and Fault Tolerance Copyright © 2008.
CSE 486/586, Spring 2013 CSE 486/586 Distributed Systems Replication with View Synchronous Group Communication Steve Ko Computer Sciences and Engineering.
Distributed Transactions Chapter 13
Distributed Systems CS Fault Tolerance- Part III Lecture 19, Nov 25, 2013 Mohammad Hammoud 1.
Distributed Systems Principles and Paradigms Chapter 07 Fault Tolerance 01 Introduction 02 Communication 03 Processes 04 Naming 05 Synchronization 06 Consistency.
1 8.3 Reliable Client-Server Communication So far: Concentrated on process resilience (by means of process groups). What about reliable communication channels?
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved DISTRIBUTED SYSTEMS.
Fault Tolerance CSCI 4780/6780. Distributed Commit Commit – Making an operation permanent Transactions in databases One phase commit does not work !!!
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved Chapter 8 Fault.
COMP 655: Distributed/Operating Systems Summer 2011 Dr. Chunbo Chu Week 7: Fault Tolerance 11/13/20151Distributed Systems - COMP 655.
ICS362 – Distributed Systems
More on Fault Tolerance Chapter 7. Topics Group Communication Virtual Synchrony Atomic Commit Checkpointing, Logging, Recovery.
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved Chapter 8 Fault.
Fault Tolerance Chapter 7.
Fault Tolerance. Basic Concepts Availability The system is ready to work immediately Reliability The system can run continuously Safety When the system.
Kyung Hee University 1/33 Fault Tolerance Chap 7.
Reliable Communication Smita Hiremath CSC Reliable Client-Server Communication Point-to-Point communication Established by TCP Masks omission failure,
V1.7Fault Tolerance1. V1.7Fault Tolerance2 A characteristic of Distributed Systems is that they are tolerant of partial failures within the distributed.
Fault Tolerance Chapter 7. Failures in Distributed Systems Partial failures – characteristic of distributed systems Goals: Construct systems which can.
Chapter 11 Fault Tolerance. Topics Introduction Process Resilience Reliable Group Communication Recovery.
Revisiting failure detectors Some of you asked questions about implementing consensus using S - how does it differ from reaching consensus using P. Here.
CSE 486/586, Spring 2012 CSE 486/586 Distributed Systems Replication Steve Ko Computer Sciences and Engineering University at Buffalo.
Fault Tolerance Chapter 7. Basic Concepts Dependability Includes Availability Reliability Safety Maintainability.
Introduction to Fault Tolerance By Sahithi Podila.
1 CHAPTER 5 Fault Tolerance Chapter 5-- Fault Tolerance.
Fault Tolerance Chapter 7. Goal An important goal in distributed systems design is to construct the system in such a way that it can automatically recover.
Fault Tolerance (2). Topics r Reliable Group Communication.
1 Fault Tolerance Chapter 8. 2 Basic Concepts Dependability Includes Availability Reliability Safety Maintainability.
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved DISTRIBUTED SYSTEMS.
Chapter 8 Fault Tolerance. Outline Introductions –Concepts –Failure models –Redundancy Process resilience –Groups and failure masking –Distributed agreement.
More on Fault Tolerance
Fault Tolerance Prof. Orhan Gemikonakli
Fault Tolerance Chap 7.
Chapter 8 Fault Tolerance Part I Introduction.
Distributed Systems CS
Distributed Systems CS
Distributed Systems CS
DISTRIBUTED SYSTEMS Principles and Paradigms Second Edition ANDREW S
Fault Tolerance CSC 8320 : AOS Class Presentation Shiraj Pokharel
Advanced Operating System
Distributed Systems CS
Distributed Systems - Comp 655
Abstractions for Fault Tolerance
Last Class: Fault Tolerance
Presentation transcript:

Chapter 7 Fault Tolerance Basic Concepts Failure Models Process Design Issues Flat vs hierarchical group Group Membership Reliable Client Server Communication Point to point Communication RPC Reliable Group Communication Atomic Multicast Two Phase Commit

Introduction Partial failure in distributed system may happen when one component is fails. May affect the operation in certain component Leaving another component totally unaffected The design goal in DS is Build a system that automatically recover from a partial failure Without seriously affecting the overall performance

Basic Concepts Dependability Includes Availability Reliability Safety Maintainability

Availability The system is ready to be used immediately In general, the system is operating correctly at any given moment and is available to performs its functions. Percentage of availability = (total elapsed time – sum of downtime)/total elapsed time 99.9% 61.32 hours

Reliability System can run continuously without failure. High reliable system is one that will most likely continue to work without interruption during a relative long period of time One measure used to define a component or system's reliability is mean time between failures (MTBF) MTBF = (total elapsed time – sum of downtime)/number of failures A related measurement is mean time to repair (MTTR). MTTR is the average time interval (usually expressed in hours) that it takes to repair a failed component.

Safety Nothing catastrophic will happen if a system temporary fails to operate correctly.

Maintainability Refers to how easy a failed system can be repaired

Terminology Failure: When a component is not living up to its specifications, a failure occurs Error: That part of a component's state that can lead to a failure Fault: The cause of an error Fault prevention: prevent the occurrence of a fault Fault tolerance: build a component in such a way that it can meet its specifications in the presence of faults

Different types of failures. Failure Models Different types of failures. Type of failure Description Crash failure A server halts, but is working correctly until it halts Omission failure Receive omission Send omission A server fails to respond to incoming requests A server fails to receive incoming messages A server fails to send messages Timing failure A server's response lies outside the specified time interval Response failure Value failure State transition failure The server's response is incorrect The value of the response is wrong The server deviates from the correct flow of control Arbitrary failure A server may produce arbitrary responses at arbitrary times

Failure Models(cont) Timing failures: The output of a component is correct, but lies outside a specified real-time interval - (performance failures: too slow) Response failures: The output of a component is incorrect Value failure: The wrong value is produced State transition failure: Execution of the component's service brings it into a wrong state

Failure Models(cont) Crash failures: A component halts but behaves correctly before halting Omission failures: A component fails to respond Receive omission: A server fails to receive incoming messages Send omission: A server fails to send messages Arbitrary failures: A component may produce arbitrary output and be subject to arbitrary timing failures

Process Resilience Protect against faulty processes by replicating and distributing computations in a group: Flat groups: Good for fault tolerance as information exchange immediately occurs with all group members; however, may impose more overhead as control is completely distributed (hard to implement). Hierarchical groups: All communication through a single coordinator  not really fault tolerant and scalable, but relatively easy to implement.

Flat Groups versus Hierarchical Groups Communication in a flat group. Communication in a simple hierarchical group

Group Membership Method for creating and deleting groups is needed Allowing process to join and leave the group Group Server Centralized Single point of failure Send a message to all groups members Want to join the group Send goodbye to leave the group

RPC Semantic in the presence of failure What can go wrong?: 1: Client can’t locate server 2: Client request is lost 3: Server crashes 4: Server response is lost 5: Client crashes

RPC Semantics The client unable to locate the server The server might be down Relatively simple – just report back to client Lost Request message Just resend message Use timer in waiting for acknowledgement msg, If the ack is not received within certain time limit, the msg will be transmit again

Server crashes are harder - you don't know what was done: RPC Semantics Server crashes are harder - you don't know what was done: A server in client-server communication Normal case Crash after execution Crash before execution

RPC Semantics(cont) Lost Reply message Client Crashes Use the timer again, resend the request Keep track of the request by having a sequence number to differentiate between the original req and a retransmission. Or by having a bit in the message header to distinguish initial request from retransmission. Client Crashes After send a request to the server Server will do the computation while there is no client waiting for the result – orphan.

Basic Reliable-Multicasting Schemes A simple solution to reliable multicasting when all receivers are known and are assumed not to fail Message transmission Reporting feedback

Atomic Multicast Definition msg is delivered to either all processes or none at all all messages are delivered in the same order to all processes Atomic Multicast is required for many applications example? Replicated Database, Bank Transactions Example: replicated database each replica is represented by a process each process needs to get the updates in the same order when a process dies and re-starts, it needs to perform the updates in order For atomic multicast, all the processes need to agree on group membership eg: how does a crashed process re-join the group

Reliable Stock Exchange Reliable Multicast Receivers Object Group External Data Feed (ORB) Bridge

Virtually Synchronous Group View: the view on the set of process contained in the group. The message multicast to group view G is delivered to each non-faulty process in G. If the sender crashes, the message may either be delivered to all the remaining process, or ignored by each of them.

Virtual Synchrony (1) The logical organization of a distributed system to distinguish between message receipt and message delivery

The principle of virtual synchronous multicast. Virtual Synchrony (2) The principle of virtual synchronous multicast.

Message Ordering Unordered multicast FIFO-ordered multicast Causally-ordered multicast Totally-ordered multicast

Message Ordering (1) Process P1 Process P2 Process P3 sends m1 receives m1 receives m2 sends m2 Three communicating processes in the same group. The ordering of events per process is shown along the vertical axis.

Message Ordering (2) Process P1 Process P2 Process P3 Process P4 sends m1 receives m1 receives m3 sends m3 sends m2 sends m4 receives m2 receives m4 Four processes in the same group with two different senders, and a possible delivery order of messages under FIFO-ordered multicasting

Implementing Virtual Synchrony (1) Multicast message m to a group of process. No guarantee that all member in G will receive m (sender may fail before transmit m to all its member) Because the sender has crashed; another process should get m from somewhere else Let every process in G keep m until all member in G have received it. m is said to be stable, if all member received it Only a stable message are allowed to be delivered

Implementing Virtual Synchrony (2) Process 4 notices that process 7 has crashed, sends a view change Process 6 sends out all its unstable messages, followed by a flush message Process 6 installs the new view when it has received a flush message from everyone else

Consist of coordinator and participants(voting phase&decision phase) Two-Phase Commit (1) Consist of coordinator and participants(voting phase&decision phase) The coordinator sends a VOTE_REQUEST message to all participants Participant may either send back the VOTE_COMMIT or VOTE_ABORT Coordinator will send GLOBAL_COMMIT if received VOTE_COMMIT from all participant; GLOBAL_ABORT if only one send VOTE_ABORT Each participant wait for message from coordinator; GLOBAL_COMMIT- Locally commit the transaction GLOBAL_ABORT - Locally abort the transaction

Two-Phase Commit (2) The finite state machine for the coordinator in 2PC. The finite state machine for a participant.

Two-Phase Commit (3) The protocol can easily fail when a process crashes; other processes may indefinitely waiting for a message from that process. Time out mechanism are use to solved the problems 1. Participant may waiting for VOTE_REQUEST in their INIT state; decide to locally abort the transaction 2. Coordinator may waiting for a message from participants in the WAIT state; send GLOBAL_ABORT 3. Participant block in READY state waiting for global vote from coordinator; participant cannot simply decide to abort the transaction; - wait for coordinator to up again; -Contact another participant to check for the current state

Two-Phase Commit (4) Coordinator Q State Coordinator Msg COMMIT GLOBAL_COMMIT ABORT GLOBAL_ABORT INIT VOTE_REQUEST READY Wait for coordinator recover READY P Q State of Q Action by P COMMIT Make transition to COMMIT ABORT Make transition to ABORT INIT READY Contact another participant Actions taken by a participant P when residing in state READY and having contacted another participant Q.