P1 : Distributed Bitcoin Miner

Slides:



Advertisements
Similar presentations
Current methods for negotiating firewalls for the Condor ® system Bruce Beckles (University of Cambridge Computing Service) Se-Chang Son (University of.
Advertisements

Computer Architecture
Introduction 1 Lecture 13 Transport Layer (Transmission Control Protocol) slides are modified from J. Kurose & K. Ross University of Nevada – Reno Computer.
Lab 9 CIS 370 Umass Dartmouth.  A pipe is typically used as a one-way communications channel which couples one related process to another.  UNIX deals.
Umut Girit  One of the core members of the Internet Protocol Suite, the set of network protocols used for the Internet. With UDP, computer.
Simulation-based Comparison of Tahoe, Reno, and SACK TCP Kevin Fall & Sally Floyd Presented: Heather Heiman September 10, 2002.
1 Transport Protocols & TCP CSE 3213 Fall April 2015.
TCP - Part I Relates to Lab 5. First module on TCP which covers packet format, data transfer, and connection management.
Transport Layer – TCP (Part2) Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF.
Slide 1 of 10 Job Event Basics A Job Event is the name for the collection of components that comprise a scheduled job. On the iSeries a the available Job.
1 TCP - Part I Relates to Lab 5. First module on TCP which covers packet format, data transfer, and connection management.
1 CS 4396 Computer Networks Lab Transmission Control Protocol (TCP) Part I.
Network Operating Systems Users are aware of multiplicity of machines. Access to resources of various machines is done explicitly by: –Logging into the.
Real-Time Authentication Using Digital Signature Schema Marissa Hollingsworth BOISECRYPT ‘09.
A CHAT CLIENT-SERVER MODULE IN JAVA BY MAHTAB M HUSSAIN MAYANK MOHAN ISE 582 FALL 2003 PROJECT.
Page: 1 Director 1.0 TECHNION Department of Computer Science The Computer Communication Lab (236340) Summer 2002 Submitted by: David Schwartz Idan Zak.
CSCI 4550/8556 Computer Networks Comer, Chapter 3: Network Programming and Applications.
1 CSI 101 Elements of Computing Fall 2009 Lecture #4 Using Flowcharts Monday February 2nd, 2009.
RPC Project Using either sockets or TLI, implement Remote Procedure Calls between two distinct machines that are communicating over an Ethernet network.
Online Chess Project 3 Due date: April 17 th. Introduction Third in series of three projects This project focuses on adding online support –2 players.
Distributed Systems 2006 Group Membership * *With material adapted from Ken Birman.
© Lethbridge/Laganière 2001 Chap. 3: Basing Development on Reusable Technology 1 Let’s get started. Let’s start by selecting an architecture from among.
WXES2106 Network Technology Semester /2005 Chapter 8 Intermediate TCP CCNA2: Module 10.
3-1 Transport services and protocols r provide logical communication between app processes running on different hosts r transport protocols run in end.
Basic Concepts of Computer Networks
Process-to-Process Delivery:
DEMIGUISE STORAGE An Anonymous File Storage System VIJAY KUMAR RAVI PRAGATHI SEGIREDDY COMP 512.
Nachos Phase 1 Code -Hints and Comments
LECTURE9 NET301. DYNAMIC MAC PROTOCOL: CONTENTION PROTOCOL Carrier Sense Multiple Access (CSMA): A protocol in which a node verifies the absence of other.
TCP/IP Essentials A Lab-Based Approach Shivendra Panwar, Shiwen Mao Jeong-dong Ryoo, and Yihan Li Chapter 5 UDP and Its Applications.
Implementing Remote Procedure Calls Authored by Andrew D. Birrell and Bruce Jay Nelson Xerox Palo Alto Research Center Presented by Lars Larsson.
© Lethbridge/Laganière 2005 Chap. 3: Basing Development on Reusable Technology The Client-Server Architecture A distributed system is a system in.
Netprog: Routing and the Network Layer1 Routing and the Network Layer (ref: Interconnections by Perlman)
CH 25-Remote Login (TELNET,Rlogin)
Chapter 24 Transport Control Protocol (TCP) Layer 4 protocol Responsible for reliable end-to-end transmission Provides illusion of reliable network to.
The Client-Server Model And the Socket API. Client-Server (1) The datagram service does not require cooperation between the peer applications but such.
LECTURE9 NET301 11/5/2015Lect 9 NET DYNAMIC MAC PROTOCOL: CONTENTION PROTOCOL Carrier Sense Multiple Access (CSMA): A protocol in which a node verifies.
4343 X2 – The Transport Layer Tanenbaum Ch.6.
Monitoring Dynamic IOC Installations Using the alive Record Dohn Arms Beamline Controls & Data Acquisition Group Advanced Photon Source.
General Purpose Grid Computing LCA. Specification The system will provide a multi-threaded, shared memory environment that is distributed across a loosely.
Chapter 3 Transport Layer
TCP - Part II.
Fast Retransmit For sliding windows flow control we waited for a timer to expire before beginning retransmission of a packet TCP uses an additional mechanism.
WWW and HTTP King Fahd University of Petroleum & Minerals
5. End-to-end protocols (part 1)
Chapter 2: System Structures
TCP.
Chapter 14 User Datagram Program (UDP)
LCGAA nightlies infrastructure
6 Transport Layer Computer Networks Tutun Juhana
Chapter 6: Transport Layer (Part I)
Internet Networking recitation #12
Net301 lecture9 11/5/2015 Lect 9 NET301.
Congestion Control, Internet transport protocols: udp
TCP - Part I Karim El Defrawy
Sarah Diesburg Operating Systems COP 4610
Processor Management Damian Gordon.
Protocol Basics.
Process-to-Process Delivery:
Remote Procedure Call (RPC)
CSE 486/586 Distributed Systems Concurrency Control --- 3
Andy Wang Operating Systems COP 4610 / CGS 5765
CPEG514 Advanced Computer Networkst
TCP - Part I Relates to Lab 5. First module on TCP which covers packet format, data transfer, and connection management.
Routing and the Network Layer (ref: Interconnections by Perlman
Process-to-Process Delivery: UDP, TCP
Processor Management Damian Gordon.
Message Passing Systems Version 2
Last Class: Communication in Distributed Systems
CSE 486/586 Distributed Systems Concurrency Control --- 3
Presentation transcript:

P1 : Distributed Bitcoin Miner 15-440/15-640 10/03/2018

Overview P1 Post-checkpoint Unit Tests P1 Part B Q&A

P1 Post-checkpoint Unit Tests TestSendReceive* TestRobust* TestWindow* TestExpBackOff* TestServerSlowStart* TestServerClose* TestServerCloseConns* TestClientClose* TestServerFastClose* TestServerToClient* TestClientToServer* TestRoundTrip* TestVariableLengthMsgServer TestVariableLengthMsgClient TestCorruptedMsgServer TestCorruptedMsgClient

TestSendReceive* TestSendReceive* test that all messages sent from one side are received by the other (without relying on epochs to resend any messages) Window size = 1 Otherwise similar to TestBasic*

TestRobust* TestRobust* test robustness by inserting random delays in between client/server reads or writes, and by increasing the packet loss to up to 20% Window size up to 10 Client count up to 5

TestWindow* TestWindow1~3 test the case that … The sliding window has reached its maximum capacity. Only 'w' unacknowledged messages can be sent out at once. TestWindow4~6 test the case that … Messages are returned by Read in the order they were sent (i.e. in order of their sequence numbers). If messages 1-5 are dropped and messages 6-10 are received, then the latter 5 should not be returned by Read until the first 5 are received.

TestExpBackOff* TestExpBackOff* test that the number of messages sent due to exponential back- off falls within a reasonable range We sniff messages sent through lspnet Up to 10 clients Up to 15 messages

TestServerSlowStart* TestServerSlowStart* test that a client is able to connect to a slow-starting server if the server starts a few epochs later than a client, the presence of epoch events should ensure that the connection is eventually established Up to 3 clients Timeout after 5 epochs

TestServerClose* TestServerCloseConns* TestClientClose* Check that the client/server Close methods work correctly Pending messages should be returned by Read and pending messages should be written and acknowledged by the other side before Close returns CloseConn should return immediately without blocking Check that no extra messages are received on the client/server

TestServerFastClose* Streaming messages in large batches and the network is toggled on/off (i.e. drop percent is set to either 0% or 100%) throughout.

TestServerFastClose* (Cont.) Test procedure at high level Wait for all servers and clients to be ready Shut down network Client application starts writing… Turn on network and delay (server-client communication resumed) Server application starts reading… Server application starts writing… Start closing server (pending messages need to be ready for send) Client application starts reading… Start closing client

TestServerToClient* TestClientToServer* TestRoundTrip* Variants of TestServerFastClose* For more details, read lsp4_test.master()

TestVariableLengthMsgServer TestVariableLengthMsgClient Check that server/client… Can read normal length message Truncates long messages Doesn't read short messages

TestCorruptedMsgServer TestCorruptedMsgClient Check that server/client… Drop Data messages whose calculated and recorded checksums don’t match

P1 Part B Implement a distributed mining infrastructure on top of the LSP you develop for part A

Mining Given Message M Unsigned integer N Find n such that 0≤𝑛≤𝑁 h𝑎𝑠ℎ 𝑀, 𝑛 ≤h𝑎𝑠ℎ 𝑀, 𝑛 ′ ∀ 0≤ 𝑛 ′ ≤𝑁 Run brute-force search to enumerate all possible scenarios across multiple machines

Architecture Miner 1 Miner 2 Join Join Server Request Request Client 1

Architecture Compute Compute Miner 1 Miner 2 Request Request Server Client 1 Client 2

Architecture Miner 1 Miner 2 Result (partial) Result (partial) Server Results Results Client 1 Client 2

Handling Failures When a miner loses contact with the server it should shut itself down. When the server loses contact with a miner, it should reassign any job that the worker was handling to a different worker. If there are no available miners left, the server should wait for a new miner to join before reassigning the old miner’s job. When the server loses contact with a request client, it should cease working on any requests being done on behalf of the client (you need not forcibly terminate a job on a miner—just wait for it to complete and ignore its results). When a request client loses contact with the server, it should print Disconnected to standard output and exit. You should design a scheduler that balances loads across all requests, so that the number of workers assigned to each outstanding request is roughly equal. Your code should contain documentation on how your scheduler achieves this requirement.

Questions I know you will ask Are there hidden tests in part B? Yes Does passing the public test mean we can pass the hidden tests? No, not even close If we fail the hidden tests on Autolab, can we get useful hints on what is wrong? Barely. You probably don’t want to waste 15 submission attempts on debugging. So write good tests!! How can we split the work? It depends. Total LOC of bitcoin implementation in our reference solution: ~360 Total LOC in hidden tests: >700 Write good tests from day 1!!