Speculative Execution in a Distributed File System Ed Nightingale Peter Chen Jason Flinn University of Michigan.

Slides:



Advertisements
Similar presentations
Remus: High Availability via Asynchronous Virtual Machine Replication
Advertisements

Rethink the Sync Ed Nightingale Kaushik Veeraraghavan Peter Chen Jason Flinn University of Michigan.
Speculative Execution In Distributed File System and External Synchrony Edmund B.Nightingale, Kaushik Veeraraghavan Peter Chen, Jason Flinn Presented by.
Parallel and Distributed Simulation Time Warp: Basic Algorithm.
Flash: An efficient and portable Web server Authors: Vivek S. Pai, Peter Druschel, Willy Zwaenepoel Presented at the Usenix Technical Conference, June.
Distributed Storage March 12, Distributed Storage What is Distributed Storage?  Simple answer: Storage that can be shared throughout a network.
Bandwidth and latency optimizations Jinyang Li w/ speculator slides from Ed Nightingale.
Speculations: Speculative Execution in a Distributed File System 1 and Rethink the Sync 2 Edmund Nightingale 12, Kaushik Veeraraghavan 2, Peter Chen 12,
Chapter 3: Processes. 3.2 Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Objectives Understand Process concept Process scheduling Creating.
Other File Systems: LFS and NFS. 2 Log-Structured File Systems The trend: CPUs are faster, RAM & caches are bigger –So, a lot of reads do not require.
I/O Hardware n Incredible variety of I/O devices n Common concepts: – Port – connection point to the computer – Bus (daisy chain or shared direct access)
CS 333 Introduction to Operating Systems Class 18 - File System Performance Jonathan Walpole Computer Science Portland State University.
CMPT 300: Operating Systems I Ch 3: Processes Dr. Mohamed Hefeeda
Remus: High Availability via Asynchronous Virtual Machine Replication.
Distributed File System: Design Comparisons II Pei Cao Cisco Systems, Inc.
16: Distributed Systems1 DISTRIBUTED SYSTEM STRUCTURES NETWORK OPERATING SYSTEMS The users are aware of the physical structure of the network. Each site.
Rensselaer Polytechnic Institute CSC 432 – Operating Systems David Goldschmidt, Ph.D.
DESIGN AND IMPLEMENTATION OF THE SUN NETWORK FILESYSTEM R. Sandberg, D. Goldberg S. Kleinman, D. Walsh, R. Lyon Sun Microsystems.
Network File System (NFS) Brad Karp UCL Computer Science CS GZ03 / M030 6 th, 7 th October, 2008.
Energy Efficiency and Storage Flexibility in the Blue File System Edmund B Nightingale Jason Flinn University of Michigan.
Transactions and Reliability. File system components Disk management Naming Reliability  What are the reliability issues in file systems? Security.
Operating System Support for Application-Specific Speculation Benjamin Wester Peter Chen and Jason Flinn University of Michigan.
CSC 456 Operating Systems Seminar Presentation (11/13/2012) Leon Weingard, Liang Xin The Google File System.
1 AutoBash: Improving Configuration Management with Operating System Causality Analysis Ya-Yunn Su, Mona Attariyan, and Jason Flinn University of Michigan.
Networked File System CS Introduction to Operating Systems.
Distributed Systems. Interprocess Communication (IPC) Processes are either independent or cooperating – Threads provide a gray area – Cooperating processes.
Distributed File Systems
I/O Systems I/O Hardware Application I/O Interface
Parallelizing Security Checks on Commodity Hardware E.B. Nightingale, D. Peek, P.M. Chen and J. Flinn U Michigan.
Lecture 3 Process Concepts. What is a Process? A process is the dynamic execution context of an executing program. Several processes may run concurrently,
Parallelizing Security Checks on Commodity Hardware Ed Nightingale Dan Peek, Peter Chen Jason Flinn Microsoft Research University of Michigan.
30 October Agenda for Today Introduction and purpose of the course Introduction and purpose of the course Organization of a computer system Organization.
SPECULATIVE EXECUTION IN A DISTRIBUTED FILE SYSTEM E. B. Nightingale P. M. Chen J. Flint University of Michigan.
LINUX System : Lecture 7 Bong-Soo Sohn Lecture notes acknowledgement : The design of UNIX Operating System.
Sun Network File System Presentation 3 Group A4 Sean Hudson, Syeda Taib, Manasi Kapadia.
Chapter 11: File System Implementation Silberschatz, Galvin and Gagne ©2005 Operating System Concepts Chapter 11: File System Implementation Chapter.
Storage Systems CSE 598d, Spring 2007 Rethink the Sync April 3, 2007 Mark Johnson.
CS333 Intro to Operating Systems Jonathan Walpole.
Silberschatz, Galvin and Gagne  2002 Modified for CSCI 399, Royden, Operating System Concepts Operating Systems Lecture 4 Computer Systems Review.
Silberschatz, Galvin and Gagne  Operating System Concepts Six Step Process to Perform DMA Transfer.
The Mach System Silberschatz et al Presented By Anjana Venkat.
Speculation Supriya Vadlamani CS 6410 Advanced Systems.
AtomCaml: First-class Atomicity via Rollback Michael F. Ringenburg and Dan Grossman University of Washington International Conference on Functional Programming.
Distributed File Systems Group A5 Amit Sharma Dhaval Sanghvi Ali Abbas.
Silberschatz, Galvin, and Gagne  Applied Operating System Concepts Module 12: I/O Systems I/O hardwared Application I/O Interface Kernel I/O.
Synchronization in Distributed File Systems Advanced Operating System Zhuoli Lin Professor Zhang.
Speculative Execution in a Distributed File System Ed Nightingale Peter Chen Jason Flinn University of Michigan Best Paper at SOSP 2005 Modified for CS739.
Free Transactions with Rio Vista Landon Cox April 15, 2016.
File System Consistency
Module 12: I/O Systems I/O hardware Application I/O Interface
Free Transactions with Rio Vista
Jonathan Walpole Computer Science Portland State University
Presented by: Daniel Taylor
Scaling a file system to many cores using an operation log
Improving File System Synchrony
Introduction to Operating Systems
CPSC 457 Operating Systems
Rethink the Sync Ed Nightingale Kaushik Veeraraghavan Peter Chen
Operating System Concepts
13: I/O Systems I/O hardwared Application I/O Interface
CS703 - Advanced Operating Systems
Free Transactions with Rio Vista
Parallel and Distributed Simulation
DESIGN AND IMPLEMENTATION OF THE SUN NETWORK FILESYSTEM
Rethink the Sync Ed Nightingale Kaushik Veeraraghavan Peter Chen
Operating Systems Lecture 1.
LINUX System : Lecture 7 Lecture notes acknowledgement : The design of UNIX Operating System.
Chapter 13: I/O Systems I/O Hardware Application I/O Interface
Module 12: I/O Systems I/O hardwared Application I/O Interface
The Design and Implementation of a Log-Structured File System
Presentation transcript:

Speculative Execution in a Distributed File System Ed Nightingale Peter Chen Jason Flinn University of Michigan

2 Motivation Why are distributed file systems slow(er)? –Sync n/w messages provide consistency –Sync disk writes provide safety Sacrifice guarantees for speed Can DFS can be safe, consistent and fast? –Yes! With OS support for speculative execution

3 Big Idea: Slow Way RPC Req Client RPC Resp Guarantees without blocking I/O! Server Block!2) Speculate! 1) Checkpoint Big Idea: Speculator 3) Correct? Yes: discard ckpt.No: restore process & re-execute RPC Req RPC Resp RPC Req RPC Resp

4 Conditions for Success Operations are highly predictable –Conflicts are rare Checkpoints are cheaper than network I/O –52 µs for small process Computers have resources to spare –Need memory and CPU cycles for speculation

5 Outline Motivation Implementing speculation Multi-process speculation Using Speculator Evaluation

6 Undo log Implementing Speculation Process Checkpoint Spec 1) System call2) Create speculation Time

7 Speculation Success Undo log Checkpoint 1) System call2) Create speculation Process 3) Commit speculation Time Spec

8 Speculation Failure Undo log Checkpoint 1) System call 2) Create speculation Process 3) Fail speculation Process Time Spec

9 Ensuring Correctness Spec processes often affect external state Three ways to ensure correct execution –Block –Buffer –Propagate speculations (dependencies)

10 Systems Calls Block calls that externalize state –Allow read-only calls (e.g. getpid) –Allow calls that modify only task state (e.g. dup2) File system calls -- need to dig deeper –Mark file systems that support Speculator getpid reboot mkdir Call sys_getpid() Block until specs resolved Allow only if fs supports Speculator

11 Output Commits “stat worked” “mkdir worked” Undo log Checkpoint Spec (stat) Spec (mkdir) 1) sys_stat2) sys_mkdir Process Time 3) Commit speculation

12 Multi-Process Speculation Processes often cooperate –Example: “make” forks children to compile, link, etc. –Would block if speculation limited to one task Allow kernel objects to have speculative state –Examples: inodes, signals, pipes, Unix sockets, etc. –Propagate dependencies among objects –Objects rolled back to prior states when specs fail

13 Spec 1 Multi-Process Speculation Spec 2 pid 8001 Checkpoint inode 3456 Chown -1 Write -1 pid 8000 Checkpoint Chown -1 Write -1

14 Multi-Process Speculation What we handle: –DFS objects, RAMFS, Ext3, Pipes & FIFOs –Unix Sockets, Signals, Fork & Exit What we don’t (i.e. we block) –System V IPC –Multi-process write-shared memory

15 Outline Motivation Implementing speculation Multi-process speculation Using Speculator Evaluation

16 Example: NFSv3 Linux Client 1Client 2Server Open B Getattr Modify B Write Commit

17 Example: SpecNFS Modify B speculate Getattr Open B speculate Open B Getattr speculate Write+Commit Client 1Client 2Server

18 Problem: Mutating Operations bar depends on cat foo What does client 2 view in bar? Client 1 1. cat foo > bar Client 2 2. cat bar

19 Solution: Mutating Operations Server determines speculation success/failure –State at server never speculative Send server hypothesis speculation based on –List of speculations an operation depends on Requires server to track failed speculations Requires in-order processing of messages

20 Group Commit Previously sequential ops now concurrent Sync ops usually committed to disk Speculator makes group commit possible write commit Client Server

21 Putting it all Together: SpecNFS Apply Speculator to an existing file system Modified NFSv3 in Linux 2.4 kernel –Same RPCs issued (but many now asynchronous) –SpecNFS has same consistency, safety as NFS –Getattr, lookup, access speculate if data in cache –Create, mkdir, commit, etc. always speculate

22 Putting it all Together: BlueFS Design a new file system for Speculator –Single copy semantics –Synchronous I/O Each file, directory, etc. has version number –Incremented on each mutating op (e.g. on write) –Checked prior to all operations. –Many ops speculate and check version async

23 Outline Motivation Implementing speculation Multi-process speculation Using Speculator Evaluation

24 Apache Benchmark SpecNFS up to 14 times faster

25 The Cost of Rollback All files out of date SpecNFS up to 11x faster

26 Conclusion Speculator greatly improves performance of existing distributed file systems Speculator enables new file systems to be safe, consistent and fast

27 Group Commit & Sharing State

28 Apache Benchmark

29 Related Work Chang & Gibson, Fraser & Chang –Speculative pre-fetching Time Warp –Virtual Time: distributed simulations Hardware branch prediction Transactional file systems