Distributed File Systems. CS 537 Lecture 15. Distributed File Systems. Transfer Model. Naming transparency 3/27/09

Similar documents
Distributed File Systems. Directory Hierarchy. Transfer Model

Distributed File Systems

NFS: Naming indirection, abstraction. Abstraction, abstraction, abstraction! Network File Systems: Naming, cache control, consistency

Advanced Operating Systems

Today: Distributed File Systems

Today: Distributed File Systems!

Background. 20: Distributed File Systems. DFS Structure. Naming and Transparency. Naming Structures. Naming Schemes Three Main Approaches

Today: Distributed File Systems. Naming and Transparency

Network File Systems

AN OVERVIEW OF DISTRIBUTED FILE SYSTEM Aditi Khazanchi, Akshay Kanwar, Lovenish Saluja

DISTRIBUTED FILE SYSTEMS & NFS

Cloud Computing CS

Distributed Systems - III

DISTRIBUTED SYSTEMS [COMP9243] Lecture 9b: Distributed File Systems INTRODUCTION. Transparency: Flexibility: Slide 1. Slide 3.

Chapter 11: Implementing File-Systems

416 Distributed Systems. Distributed File Systems 2 Jan 20, 2016

Lecture 7: Distributed File Systems

Chapter 17: Distributed-File Systems. Operating System Concepts 8 th Edition,

Introduction to Cloud Computing

File-System Structure

Chapter 11 DISTRIBUTED FILE SYSTEMS

Distributed File Systems. CS432: Distributed Systems Spring 2017

CSE 486/586: Distributed Systems

Lecture 14: Distributed File Systems. Contents. Basic File Service Architecture. CDK: Chapter 8 TVS: Chapter 11

Distributed File Systems. Distributed Systems IT332

CS 425 / ECE 428 Distributed Systems Fall Indranil Gupta (Indy) Nov 28, 2017 Lecture 25: Distributed File Systems All slides IG

Bhaavyaa Kapoor Person #

Announcements. Reading: Chapter 16 Project #5 Due on Friday at 6:00 PM. CMSC 412 S10 (lect 24) copyright Jeffrey K.

Module 17: Distributed-File Systems

EI 338: Computer Systems Engineering (Operating Systems & Computer Architecture)

Chapter 11: File System Implementation

Chapter 11: File System Implementation

Chapter 11: Implementing File Systems

Operating Systems Design 16. Networking: Remote File Systems

Module 17: Distributed-File Systems

Filesystems Lecture 11

416 Distributed Systems. Distributed File Systems 1: NFS Sep 18, 2018

Lecture 19. NFS: Big Picture. File Lookup. File Positioning. Stateful Approach. Version 4. NFS March 4, 2005

Today: Coda, xfs! Brief overview of other file systems. Distributed File System Requirements!

What is a file system

Chapter 17: Distributed-File Systems. Operating System Concepts 8 th Edition,

Filesystems Lecture 13

Today: Distributed File Systems. File System Basics

Today: Distributed File Systems

Extreme computing Infrastructure

Chapter 11: Implementing File Systems

Section 14: Distributed Storage

Chapter 12 File-System Implementation

DFS Case Studies, Part 2. The Andrew File System (from CMU)

OPERATING SYSTEM. Chapter 12: File System Implementation

Today CSCI Coda. Naming: Volumes. Coda GFS PAST. Instructor: Abhishek Chandra. Main Goals: Volume is a subtree in the naming space

Chapter 11: Implementing File Systems

CS 537: Introduction to Operating Systems Fall 2015: Midterm Exam #4 Tuesday, December 15 th 11:00 12:15. Advanced Topics: Distributed File Systems

Distributed Systems. Lec 9: Distributed File Systems NFS, AFS. Slide acks: Dave Andersen

Chapter 11: Implementing File Systems

COSC 6374 Parallel Computation. Parallel I/O (I) I/O basics. Concept of a clusters

Network File System (NFS)

Network File System (NFS)

Distributed file systems

Distributed File Systems I

C 1. Recap. CSE 486/586 Distributed Systems Distributed File Systems. Traditional Distributed File Systems. Local File Systems.

CS307: Operating Systems

Introduction. Chapter 8: Distributed File Systems

Chapter 12: File System Implementation

Distributed File Systems: Design Comparisons

Chapter 18 Distributed Systems and Web Services

System that permanently stores data Usually layered on top of a lower-level physical storage medium Divided into logical units called files

Chapter 10: File System Implementation

OPERATING SYSTEMS II DPL. ING. CIPRIAN PUNGILĂ, PHD.

Introduction. Distributed file system. File system modules. UNIX file system operations. File attribute record structure

Chapter 12: File System Implementation. Operating System Concepts 9 th Edition

Chapter 12: File System Implementation

Distributed File Systems. Jonathan Walpole CSE515 Distributed Computing Systems

06-Dec-17. Credits:4. Notes by Pritee Parwekar,ANITS 06-Dec-17 1

Distributed File Systems. Distributed Computing Systems. Outline. Concepts of Distributed File System. Concurrent Updates. Transparency 2/12/2016

Chapter 11: Implementing File

Chapter 11: Implementing File Systems. Operating System Concepts 9 9h Edition

CS454/654 Midterm Exam Fall 2004

Operating Systems 2010/2011

File-System Interface

Chapter 17: Distributed Systems (DS)

Cloud Computing CS

Network File System (NFS)

Distributed File Systems. File Systems

Week 11/12: Distributed File Systems & RPC Reading: Text, Chapter 8.2.4, 8.3,

Distributed Systems. Distributed File Systems. Paul Krzyzanowski

Distributed File Systems Part II. Distributed File System Implementation

Multi-level Translation. CS 537 Lecture 9 Paging. Example two-level page table. Multi-level Translation Analysis

Week 12: File System Implementation

3/4/14. Review of Last Lecture Distributed Systems. Topic 2: File Access Consistency. Today's Lecture. Session Semantics in AFS v2

The Google File System

Example File Systems Using Replication CS 188 Distributed Systems February 10, 2015

File systems: management 1

Chapter 13: I/O Systems

CS 470 Spring Distributed Web and File Systems. Mike Lam, Professor. Content taken from the following:

Distributed Systems. Lecture 07 Distributed File Systems (1) Tuesday, September 18 th, 2018

NETWORKED STORAGE AND REMOTE PROCEDURE CALLS (RPC)

Frequently asked questions from the previous class survey

Service and Cloud Computing Lecture 10: DFS2 Prof. George Baciu PQ838

Operating Systems, Fall

Transcription:

Distributed File Systems CS 537 Lecture 15 Distributed File Systems Michael Swift Goal: view a distributed system as a file system Storage is distributed Web tries to make world a collection of hyperlinked documents Issues not common to usual file systems Naming transparency Load balancing Scalability Location and network transparency Fault tolerance We will look at some of these today 2004-2007 Ed Lazowska, Hank Levy, Andrea and 1 2 Transfer Model Upload/download Model: Client downloads file, works on it, and writes it back on server Simple and good performance Remote Access Model: File only on server; client sends commands to get work done 3 Naming transparency Naming is a mapping from logical to physical objects Ideally client interface should be transparent Not distinguish between remote and local files /machine/path or mounting remote FS in local hierarchy are not transparent A transparent DFS hides the location of files in system 2 forms of transparency: Location transparency: path gives no hint of file location /server1/dir1/dir2/x tells x is on server1, but not where server1 is Location independence: move files without changing names Separate naming hierarchy from storage devices hierarchy 4 1

Caching Keep repeatedly accessed blocks in cache Improves performance of further accesses How it works: If needed block not in cache, it is fetched and cached Accesses performed on local copy One master file copy on server, other copies distributed in DFS Cache consistency problem: how to keep cached copy consistent with master file copy Where to cache? Disk: Pros: more reliable, data present locally on recovery Memory: Pros: diskless workstations, quicker data access, Servers maintain cache in memory 5 Network File System (NFS) Developed by Sun Microsystems in 1984 Used to join FSes on multiple computers as one logical whole Used commonly today with UNIX systems Assumptions Allows arbitrary collection of users to share a file system Clients and servers might be on different LANs Machines can be clients and servers at the same time Architecture: A server exports one or more of its directories to remote clients Clients access exported directories by mounting them The contents are then accessed as if they were local 6 Example NFS NFS defines a set of RPC operations for remote file access: searching a directory reading directory entries manipulating links and directories reading/writing files Every node may be both a client and server. 7 8 2

Remote Procedure Call Basic problem when dealing with machine across a network: how do you write the code to communicate? Option 1: messages Programmer copies message into an array of bytes, sends to other computer, receives an array of bytes in response at some point Option 2: RPC Make a procedure call that executes on the other side Tool generates code to copy arguments into a message, send data, unpack data, call server code, copy result into a message, send back, receive reply, and return to caller 9 NFS Protocol Supports directory and file access via remote procedure calls (RPCs) All UNIX system calls supported other than open & close Open and close are intentionally not supported For a read, client sends lookup message to server Server looks up file and returns handle Unlike open, lookup does not copy info in internal system tables Subsequently, read contains file handle, offset and num bytes Each message is self-contained Pros: server is stateless, i.e. no state about open files 10 Cons: Locking is difficult, no concurrency control NFS Implementation NFS Layer Structure Three main layers: System call layer: Handles calls like open, read and close Virtual File System Layer: Maintains table with one entry (v-node) for each open file v-nodes indicate if file is local or remote If remote it has enough info to access them For local files, FS and i-node are recorded NFS Service Layer: This lowest layer implements the NFS protocol 11 12 3

Cache coherency Clients cache file attributes and data If two clients cache the same data, cache coherency is lost Solutions: Each cache block has a timer (3 sec for data, 30 sec for dir) Entry is discarded when timer expires On open of cached file, its last modify time on server is checked If cached copy is old, it is discarded Every 30 sec, cache time expires All dirty blocks are written back to the server Andrew File System (AFS) Developed at CMU to support all of its student computing. Consists of workstation clients and dedicated file server machines. Workstations have local disks, used to cache files being used locally (originally whole files, now 64K file chunks). Andrew has a single name space -- your files have the same names everywhere in the world. Andrew is good for distant operation because of its local disk caching: after a slow startup, most accesses are to local disk. 13 14 AFS Overview Based on the upload/download model Clients download and cache files Server keeps track of clients that cache the file Clients upload files at end of session Whole file caching is central idea behind AFS Later amended to block operations Simple, effective AFS servers are stateful Keep track of clients that have cached files Recall files that have been modified AFS Details Has dedicated server machines Clients have partitioned name space: Local name space and shared name space Cluster of dedicated AFS servers present shared name space AFS file name works anywhere: /afs/cs.wisc.edu/u/s/w/swift 15 16 4

AFS: Operations and Consistency AFS caches entire files from servers Client interacts with servers only during open and close OS on client intercepts calls, and passes it to AFS service on client (Venus) Venus is a client process that caches files from servers Venus contacts AFS server only on open and close Does not contact if file is already in the cache, and not invalidated Reads and writes bypass Venus and go right to file cached in local file system. AFS Caching and Consistency Need for scaling led to reduction of client-server message traffic. Once a file is cached, all operations are performed locally. Cache is on disk, so normal FS and FS operations work here On close, if the file is modified, it is replaced on the server. What happens when multiple clients share a file? The client assumes that its cache is up to date, unless it receives a callback message from the server saying otherwise. On file open, if the client has received a callback on the file, it must fetch a new copy; otherwise it uses its locally-cached copy. How does this compare to NFS? 17 18 Summary NFS: Simple distributed file system protocol. No open/close Stateless server Has problems with cache consistency, locking protocol AFS: More complicated distributed file system protocol Stateful server session semantics: consistency on close 19 5