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

Similar documents
Distributed File Systems. File Systems

Distributed File Systems. CS432: Distributed Systems Spring 2017

Lecture 7: Distributed File Systems

Chapter 12 Distributed File Systems. Copyright 2015 Prof. Amr El-Kadi

CSE 486/586: Distributed Systems

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

Introduction. Chapter 8: Distributed File Systems

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

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

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

DFS Case Studies, Part 1

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

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

Chapter 8: Distributed File Systems. Introduction File Service Architecture Sun Network File System The Andrew File System Recent advances Summary

Filesystems Lecture 11

Module 7 File Systems & Replication CS755! 7-1!

Network File Systems

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

Today: Distributed File Systems. File System Basics

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

Today: Distributed File Systems

Advanced Operating Systems

Distributed File Systems I

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

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

Distributed File Systems

Today: Distributed File Systems!

Filesystems Lecture 13

Chapter 8 Distributed File Systems

Today: Distributed File Systems

Distributed File Systems

Distributed File Systems. Case Studies: Sprite Coda

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

Today: Distributed File Systems. Naming and Transparency

Ch. 7 Distributed File Systems

Filesystem. Disclaimer: some slides are adopted from book authors slides with permission

Distributed Systems. Hajussüsteemid MTAT Distributed File Systems. (slides: adopted from Meelis Roos DS12 course) 1/25

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

Frequently asked questions from the previous class survey

Operating Systems Design 16. Networking: Remote File Systems

Distributed file systems

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

Filesystem. Disclaimer: some slides are adopted from book authors slides with permission 1

Disconnected Operation in the Coda File System

Distributed File Systems. Jonathan Walpole CSE515 Distributed Computing Systems

Distributed 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

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

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

Distributed File Systems. Distributed Systems IT332

Frequently asked questions from the previous class survey

Bhaavyaa Kapoor Person #

Lecture 5: RMI etc. Servant. Java Remote Method Invocation Invocation Semantics Distributed Events CDK: Chapter 5 TVS: Section 8.3

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

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

Motivation. Operating Systems. File Systems. Outline. Files: The User s Point of View. File System Concepts. Solution? Files!

Outline. Operating Systems. File Systems. File System Concepts. Example: Unix open() Files: The User s Point of View

Remote Procedure Call (RPC) and Transparency

File-System Structure

Chapter 11: Implementing File-Systems

Da-Wei Chang CSIE.NCKU. Professor Hao-Ren Ke, National Chiao Tung University Professor Hsung-Pin Chang, National Chung Hsing University

CS454/654 Midterm Exam Fall 2004

Chapter 11: Implementing File Systems

Files & I/O. Today. Comp 104: Operating Systems Concepts. Operating System An Abstract View. Files and Filestore Allocation

OPERATING SYSTEM. Chapter 12: File System Implementation

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

Distributed Systems 8L for Part IB. Additional Material (Case Studies) Dr. Steven Hand

NETWORKED STORAGE AND REMOTE PROCEDURE CALLS (RPC)

Chapter 11: Implementing File Systems

Operating Systems 2010/2011

Module 17: Distributed-File Systems

Lecture 2 Distributed Filesystems

Announcements. P4: Graded Will resolve all Project grading issues this week P5: File Systems

NFS Design Goals. Network File System - NFS

THE ANDREW FILE SYSTEM BY: HAYDER HAMANDI

Network File System (NFS)

Network File System (NFS)

CS370: Operating Systems [Spring 2017] Dept. Of Computer Science, Colorado State University

Extreme computing Infrastructure

Module 17: Distributed-File Systems

ò Server can crash or be disconnected ò Client can crash or be disconnected ò How to coordinate multiple clients accessing same file?

What is a file system

NFS. Don Porter CSE 506

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

Chapter 11: File System Implementation

Introduction to Distributed Computing

Operating Systems, Fall

Chapter 11: File System Implementation

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

Chapter 11 DISTRIBUTED FILE SYSTEMS

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

Chapter 11: Implementing File Systems

File Concept Access Methods Directory and Disk Structure File-System Mounting File Sharing Protection

Chapter 11: Implementing File Systems

Cloud Computing CS

Chapter 12: File System Implementation

Chapter 12 File-System Implementation

File System (FS) Highlights

UNIX File System. UNIX File System. The UNIX file system has a hierarchical tree structure with the top in root.

Filesystem. Disclaimer: some slides are adopted from book authors slides with permission 1

Transcription:

Lecture 14: Distributed File Systems CDK: Chapter 8 TVS: Chapter 11 Contents General principles Sun Network File System (NFS) Andrew File System (AFS) 18-Mar-11 COMP28112 Lecture 14 2 Basic File Service Architecture Directory service maps from names to unique file identifiers (e.g. inode numbers) Flat file service provides operations on files identified by these identifiers As directories are generally themselves files, the directory service uses the facilities of the flat file service in translating hierachic path names 18-Mar-11 COMP28112 Lecture 14 3 1

Idempotent versions of Operations Operations done by RPC Normal UNIX file operations rely on the system to remember position-in-the-file information for the process Such operations are not idempotent! Can create idempotent versions by making position part of read and write calls 18-Mar-11 COMP28112 Lecture 14 4 Stateless servers Making each interaction of a client with the server less dependent on previous interactions has advantages when servers and clients might reboot at any time, or messages might be lost So try to eliminate/minimise what the server remembers for the client 18-Mar-11 COMP28112 Lecture 14 5 Access checking On a simple UNIX system, access permissions can be checked when the file is opened and the process cannot tamper with the file descriptor it is then given With stateless interactions, each operation has to be checked so pass over userid, etc with each read/write (but still potential security problem!) 18-Mar-11 COMP28112 Lecture 14 6 2

Caching leads to problems For efficiency it is vital to using caching On a single machine this can be done without any effect on semantics of file operations In a distributed system client caching can lead to noticeable differences (see below) 18-Mar-11 COMP28112 Lecture 14 7 Sun NFS Initially developed for network of Unix machines in the 1980s Now a system-independent protocol Remote filestore is mounted in the client machine s hierachy NFS can be one of many file systems running under Virtual File System (VFS) 18-Mar-11 COMP28112 Lecture 14 8 NFS architecture Client computer Server computer UNIX system calls Application Local Application Virtual file system Remote Virtual file system UNIX file system Other file system NFS client NFS protocol NFS server UNIX file system 18-Mar-11 COMP28112 Lecture 14 9 3

Local and remote file systems accessible on an NFS client Server 1 (root) Client Server 2 (root) (root) export... vmunix usr nfs people Remote mount students x staff Remote mount users big jon bob... jim ann jane joe 18-Mar-11 COMP28112 Lecture 14 10 Automounter Could make client construct whole directory tree at boot time but this would be slow and quite possibly inefficient Automounter does it on demand when an empty mount point is referenced Simple read-only replication available client can probe several servers and use first to reply! 18-Mar-11 COMP28112 Lecture 14 11 Caching Server side caching works as normal and doesn t lead to any problems Client side caching has potential for problems because writes to a file do not affect cached versions Server has no knowledge of file sharing! Client has to use a timestamp based mechanism to validate cached blocks 18-Mar-11 COMP28112 Lecture 14 12 4

Using timestamps A cache entry is valid for a time t after it was last validated For files, t is 3-30 secs For directories, t is 30-60 secs Client also holds Tm (time last modified at the server) and can revalidate by checking this is the same as is held by the server 18-Mar-11 COMP28112 Lecture 14 13 AFS Developed at Carnegie-Mellon Uni (CMU) Wanted to maximise scalability by minimising client-server interactions Late 1980s Since incorporated into more advanced file systems (e.g. Coda which addresses replication and detached working issues) 18-Mar-11 COMP28112 Lecture 14 14 Basic principles of AFS Whole file serving files up to 64KB in size are transmitted between client and server Whole file caching served files are kept on client s local disk, and these are used rather than remote ones when available Quite large local caches e.g. 100 MB 18-Mar-11 COMP28112 Lecture 14 15 5

Andrew File System Workstations Venus User Servers Vice User Venus Network Vice Venus User 18-Mar-11 COMP28112 Lecture 14 16 File name space for clients of AFS Local / (root) Shared tmp bin... vmunix cmu bin Symbolic links 18-Mar-11 COMP28112 Lecture 14 17 Callback promises These provide a way for updating cached copies When a client writing to a file closes it, the modified file is returned to the server It makes an RPC (a callback) to each client which opened that file (and hasn t closed it) A client receiving this, marks the promise as cancelled so that subsequent opens don t use it 18-Mar-11 COMP28112 Lecture 14 18 6

And timestamps Venus also uses timestamps in case callbacks happen when the client is down, or the RPC goes missing So it renews callbacks before an open if time T (typically a few mins) has elapsed Note: callbacks imply servers are no longer stateless! 18-Mar-11 COMP28112 Lecture 14 19 Semantics of sharing This has changed a bit from UNIX model If have multiple writers to a file all but the last close will effectively be lost! It is a download/upload system, rather than a remote working version of UNIX which NFS nearly provides Specifically exclude using files for databases 18-Mar-11 COMP28112 Lecture 14 20 Based on observations Files are usually small ( < 10KB) Reads are about 6 * writes Sequential access common, random access rare Most files have only a single user Even shared files usually only 1 writer Files are referenced in bursts 18-Mar-11 COMP28112 Lecture 14 21 7

Conclusions NFS-4 has callbacks (above was NFS-3)! AFS and NFS both provide a useful service They are just two examples chosen because there are significant differences between them 18-Mar-11 COMP28112 Lecture 14 22 8