Distributed Systems ETH 2020
Distributed Systems Lecture ETH 2020
Distributed Systems Lecture ETH 2020
Kartei Details
Karten | 129 |
---|---|
Sprache | English |
Kategorie | Elektrotechnik |
Stufe | Universität |
Erstellt / Aktualisiert | 15.01.2021 / 20.01.2024 |
Weblink |
https://card2brain.ch/box/20210115_distributed_systems_eth_2020
|
Einbinden |
<iframe src="https://card2brain.ch/box/20210115_distributed_systems_eth_2020/embed" width="780" height="150" scrolling="no" frameborder="0"></iframe>
|
Lernkarteien erstellen oder kopieren
Mit einem Upgrade kannst du unlimitiert Lernkarteien erstellen oder kopieren und viele Zusatzfunktionen mehr nutzen.
Melde dich an, um alle Karten zu sehen.
What is chain-based and BFT-based proof-of-stake?
- Chain: Accounts hold lottery tickets according to their stake. The lottery is pseudo-random, in the sense that hash functions computed on the state of the blockchain will select which account is winning. The winning account can extend the longest chain by a block, and earn the block reward.
- BFT: The lottery winner only gets to propose a block to be added to the blockchain. A committee then votes (yes, byzantine fault tolerance) whether to accept that block into the blockchain. If no agreement is reached, this process is repeated.
Fork problem, nothing at stake attack: just extend all forks
What is the system model for the Practical Byzantine Fault Tolerance (PBFT) protocol?
We consider a system with n = 3f +1 nodes, and additionally an unbounded number of clients. There are at most f byzantine nodes, and clients can be byzantine as well. The network is asynchronous, and messages have variable delay and can get lost. Clients send requests that correct nodes have to order to achieve state replication.
Each node will consider one node to be primary and the rest backups.
What is a view in PBFT context?
A view v is a non-negative integer representing the node’s local perception of the system. We say that node u is in view v as long as node u considers node p = v mod n to be the primary.
Give a high level overview of the PBFT agreement protocol.
1. The nodes receive a request and relay it to the primary.
2. The primary sends a pre-prepare-message to all backups, informing them that it wants to execute that request with the sequence number specified in the message.
3. Backups send prepare-messages to all nodes, informing them that they agree with that suggestion. (Needs 2f including its own)
4. All nodes send commit-messages to all nodes, informing everyone that they have committed to execute the request with that sequence number. (needs 2f+1 including its own)
5. They execute the request and inform the client.
What does the PBFT Prepare Phase look like?
What is the PBFT faulty timer?
When backup b accepts request r it starts a local faulty-timer that will only stop once b executes r. If it expires the backup considers the primary faulty and triggers a view change.
What is the goal of mechanism design?
Design a game in which nodes have an incentive to behave nicely.
What is a ticket and what properties does it have?
A ticket is a weaker form of a lock with the following properties:
- reissuable: server can issue more tickets even if previous ones not yet returned
- expiration: server only accepts most recently issued ticket
Define consensus and name its properties.
There are n nodes of which at most f might crash (n-f correct). Node i starts with an input value v_i. The nodes must decide for one of those values satisfying the following properties:
- agreement: all correct nodes decide for the same value
- termination: all correct nodes terminate in finite time
- validity: the decision must be an input value of a node
Define configuration and critical configuration.
- We say that a system is fully defined (at any point during the execution) by its configuration C. The configuration includes the state of every node, and all messages that are in transit (sent but not yet received).
- C is critical if C is bivalent but all configurations that are direct children of C are univalent
Define univalent and bivalent.
- A configuration C is univalent if the decision value is determined independently of what happens afterwards (only one decision is possible). (univalent for value v -> v-valent)
Nodes need not be aware of this! - C is bivalent if the nodes might decide for 0 or 1
Define configuration tree.
The configuration tree is a directed tree of configurations. Its root is C0 (fully characterised by the input values), The edges are transitions (characterised by event (u,m), node u receiving message m), every configuration has all applicable transitions as outgoing edges.
Is there a deterministic algorithm which always achieves consensus in the asynchronous model with f>0?
No.
If a system is in a bivalent configuration it must reach a critical configuration within finite time or it does not always solve consensus.
If a config tree contains a critical configuration crashing a single node can create a bivalent leaf
--> NO
Define byzantine.
A node which can have arbitrary behaviour (also malicious) is called byzantine.
Define 4 different kinds of validity.
- any-input validity: decision value must be the input of any node
- correct-input validity: decision value must the the input of a correct node
- all-same validity: if all correct nodes start with the same input v, the decision value must be v
- median validity: if the input values are orderable byzantine outliers can be prevented by agreeing on a value close to the median of the correct input values
What is the max. number of byzantine nodes such that byzantine agreement can be reached?
f < n/3
How many rounds does a synchronous algorithm solving consensus in the presenece of f crashing nodes need if nodes decide for the minimum seen value?
f+1
-
- 1 / 129
-