Byzantine Fault Tolerance CS 425: Distributed Systems Fall 2012 Lecture 26 November 29, 2012 Presented By: Imranul Hoque 1.

Slides:



Advertisements
Similar presentations
NETWORK ALGORITHMS Presenter- Kurchi Subhra Hazra.
Advertisements

CS 5204 – Operating Systems1 Paxos Student Presentation by Jeremy Trimble.
CSE 486/586, Spring 2013 CSE 486/586 Distributed Systems Byzantine Fault Tolerance Steve Ko Computer Sciences and Engineering University at Buffalo.
1 Attested Append-Only Memory: Making Adversaries Stick to their Word Byung-Gon Chun (ICSI) October 15, 2007 Joint work with Petros Maniatis (Intel Research,
1 Principles of Reliable Distributed Systems Lectures 11: Authenticated Byzantine Consensus Spring 2005 Dr. Idit Keidar.
Yee Jiun Song Cornell University. CS5410 Fall 2008.
CS 582 / CMPE 481 Distributed Systems
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 16 Wenbing Zhao Department of Electrical and Computer Engineering.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 15 Wenbing Zhao Department of Electrical and Computer Engineering.
Attested Append-only Memory: Making Adversaries Stick to their Word Distributed Storage Systems CS presented by: Hussam Abu-Libdeh.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 16 Wenbing Zhao Department of Electrical and Computer Engineering.
Last Class: Weak Consistency
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 15 Wenbing Zhao Department of Electrical and Computer Engineering.
Practical Byzantine Fault Tolerance (The Byzantine Generals Problem)
BASE: Using Abstraction to Improve Fault Tolerance Rodrigo Rodrigues, Miguel Castro, and Barbara Liskov MIT Laboratory for Computer Science and Microsoft.
EEC 688 Secure and Dependable Computing Lecture 16 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
Byzantine fault tolerance
Byzantine Fault Tolerance CS 425: Distributed Systems Fall Material drived from slides by I. Gupta and N.Vaidya.
Problem Computer systems provide crucial services Computer systems fail –natural disasters –hardware failures –software errors –malicious attacks Need.
1 The Design of a Robust Peer-to-Peer System Gisik Kwon Dept. of Computer Science and Engineering Arizona State University Reference: SIGOPS European Workshop.
Chapter 19 Recovery and Fault Tolerance Copyright © 2008.
EEC 688/788 Secure and Dependable Computing Lecture 14 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
HQ Replication: Efficient Quorum Agreement for Reliable Distributed Systems James Cowling 1, Daniel Myers 1, Barbara Liskov 1 Rodrigo Rodrigues 2, Liuba.
Practical Byzantine Fault Tolerance
Practical Byzantine Fault Tolerance Jayesh V. Salvi
Byzantine fault-tolerance COMP 413 Fall Overview Models –Synchronous vs. asynchronous systems –Byzantine failure model Secure storage with self-certifying.
From Viewstamped Replication to BFT Barbara Liskov MIT CSAIL November 2007.
1 ZYZZYVA: SPECULATIVE BYZANTINE FAULT TOLERANCE R.Kotla, L. Alvisi, M. Dahlin, A. Clement and E. Wong U. T. Austin Best Paper Award at SOSP 2007.
Byzantine fault tolerance
Practical Byzantine Fault Tolerance and Proactive Recovery
Robustness in the Salus scalable block store Yang Wang, Manos Kapritsos, Zuocheng Ren, Prince Mahajan, Jeevitha Kirubanandam, Lorenzo Alvisi, and Mike.
EECS 262a Advanced Topics in Computer Systems Lecture 25 Byzantine Agreement November 28 th, 2012 John Kubiatowicz and Anthony D. Joseph Electrical Engineering.
CSE 60641: Operating Systems Implementing Fault-Tolerant Services Using the State Machine Approach: a tutorial Fred B. Schneider, ACM Computing Surveys.
EEC 688/788 Secure and Dependable Computing Lecture 15 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
UNIVERSITY of WISCONSIN-MADISON Computer Sciences Department
Byzantine Fault Tolerance
Systems Research Barbara Liskov October Replication Goal: provide reliability and availability by storing information at several nodes.
Fault Tolerance
Robustness in the Salus scalable block store Yang Wang, Manos Kapritsos, Zuocheng Ren, Prince Mahajan, Jeevitha Kirubanandam, Lorenzo Alvisi, and Mike.
Fail-Stop Processors UNIVERSITY of WISCONSIN-MADISON Computer Sciences Department CS 739 Distributed Systems Andrea C. Arpaci-Dusseau One paper: Byzantine.
BChain: High-Throughput BFT Protocols
Byzantine Fault Tolerance
Principles of Computer Security
View Change Protocols and Reconfiguration
Byzantine Fault Tolerance
Providing Secure Storage on the Internet
Principles of Computer Security
Jacob Gardner & Chuan Guo
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
IS 651: Distributed Systems Byzantine Fault Tolerance
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
From Viewstamped Replication to BFT
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
Building Dependable Distributed Systems, Copyright Wenbing Zhao
View Change Protocols and Reconfiguration
John Kubiatowicz Electrical Engineering and Computer Sciences
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
EEC 688/788 Secure and Dependable Computing
Sisi Duan Assistant Professor Information Systems
Presentation transcript:

Byzantine Fault Tolerance CS 425: Distributed Systems Fall 2012 Lecture 26 November 29, 2012 Presented By: Imranul Hoque 1

Reading List L. Lamport, R. Shostak, M. Pease, “The Byzantine Generals Problem,” ACM ToPLaS M. Castro and B. Liskov, “Practical Byzantine Fault Tolerance,” OSDI

Problem Computer systems provide crucial services Computer systems fail – Crash-stop failure – Crash-recovery failure – Byzantine failure Example: natural disaster, malicious attack, hardware failure, software bug, etc. Need highly available service 3 Replicate to increase availability

Byzantine Generals Problem All loyal generals decide upon the same plan A small number of traitors can’t cause the loyal generals to adopt a bad plan 4 Solvable if more than two-third of the generals are loyal Attack Retreat Attack Attack/Retreat

Practical Byzantine Fault Tolerance Before PBFT: BFT was considered too impractical in practice Practical replication algorithm – Weak assumption (BFT, asynchronous) – Good performance Implementation – BFT: A generic replication toolkit – BFS: A replicated file system Performance evaluation Byzantine Fault Tolerance in Asynchronous Environment 5

Challenges 6 Request A Request B Client

Challenges 7 2: Request B 1: Request A Client

State Machine Replication 8 2: Request B 1: Request A 2: Request B 1: Request A 2: Request B 1: Request A 2: Request B 1: Request A Client How to assign sequence number to requests?

Primary Backup Mechanism 9 Client 2: Request B 1: Request A What if the primary is faulty? Agreeing on sequence number Agreeing on changing the primary (view change) What if the primary is faulty? Agreeing on sequence number Agreeing on changing the primary (view change) View 0

Agreement Certificate: set of messages from a quorum Algorithm steps are justified by certificates Quorum B Quorum A Quorums have at least 2f + 1 replicas Quorums intersect in at least one correct replica 10

Algorithm Components Normal case operation View changes Garbage collection State transfer Recovery All have to be designed to work together 11

Normal Case Operation Three phase algorithm: – PRE-PREPARE picks order of requests – PREPARE ensures order within views – COMMIT ensures order across views Replicas remember messages in log Messages are authenticated – {.} σk denotes a message sent by k 12 Quadratic message exchange

Pre-prepare Phase Primary: Replica 0 Replica 1 Replica 2 Replica 3 Request: m {PRE-PREPARE, v, n, m} σ0 Fail 13

Prepare Phase Request: m PRE-PREPARE Primary: Replica 0 Replica 1 Replica 2 Replica 3 Fail Accepted PRE-PREPARE 14

Prepare Phase Request: m PRE-PREPARE Primary: Replica 0 Replica 1 Replica 2 Replica 3 Fail {PREPARE, v, n, D(m), 1} σ1 Accepted PRE-PREPARE 15

Prepare Phase Request: m PRE-PREPARE Primary: Replica 0 Replica 1 Replica 2 Replica 3 Fail {PREPARE, v, n, D(m), 1} σ1 Accepted PRE-PREPARE Collect PRE-PREPARE + 2f matching PREPARE 16

Commit Phase Request: m PRE-PREPARE Primary: Replica 0 Replica 1 Replica 2 Replica 3 Fail PREPARE {COMMIT, v, n, D(m)} σ2 17

Commit Phase (2) Request: m PRE-PREPARE Primary: Replica 0 Replica 1 Replica 2 Replica 3 Fail PREPARE COMMIT Collect 2f+1 matching COMMIT: execute and reply 18

View Change Provide liveness when primary fails – Timeouts trigger view changes – Select new primary (= view number mod 3f+1) Brief protocol – Replicas send VIEW-CHANGE message along with the requests they prepared so far – New primary collects 2f+1 VIEW-CHANGE messages – Constructs information about committed requests in previous views 19

View Change Safety Goal: No two different committed request with same sequence number across views Quorum for Committed Certificate (m, v, n) At least one correct replica has Prepared Certificate (m, v, n) At least one correct replica has Prepared Certificate (m, v, n) View Change Quorum View Change Quorum 20

Recovery Corrective measure for faulty replicas – Proactive and frequent recovery – All replicas can fail if at most f fail in a window System administrator performs recovery, or Automatic recovery from network attacks – Secure co-processor – Read-only memory – Watchdog timer 21 Clients will not get reply if more than f replicas are recovering

Sketch of Recovery Protocol Save state Reboot with correct code and restore state – Replica has correct code without losing state Change keys for incoming messages – Prevent attacker from impersonating others Send recovery request r – Others change incoming keys when r execute Check state and fetch out-of-date or corrupt items – Replica has correct up-to-date state 22

Optimizations Replying with digest Request batching Optimistic execution 23

Performance Andrew benchmark – Andrew100 and Andrew500 4 machines: 600 MHz, Pentium III 3 Systems – BFS: based on BFT – NO-REP: BFS without replication – NFS: NFS-V2 implementation in Linux 24 No experiment with faulty replicas Scalability issue: only 4 & 7 replicas No experiment with faulty replicas Scalability issue: only 4 & 7 replicas

Benchmark Results 25 Without view change and faulty replica!

Related Works Fault Tolerance Fail Stop Fault Tolerance Paxos 1989 (TR) VS Replication PODC 1988 Byzantine Fault Tolerance Byzantine Agreement Rampart TPDS 1995 SecureRing HICSS 1998 PBFT OSDI ‘99 BASE TOCS ‘03 Byzantine Quorums Malkhi-Reiter JDC 1998 Phalanx SRDS 1998 Fleet ToKDI ‘00 Q/U SOSP ‘05 Hybrid Quorum HQ Replication OSDI ‘06 26

Questions? 27