Consistency in NFS and AFS Network File System

  • Slides: 17
Download presentation
Consistency in NFS and AFS

Consistency in NFS and AFS

Network File System (NFS) • Uses client caching to reduce network load • Built

Network File System (NFS) • Uses client caching to reduce network load • Built on top of RPC Server cache: X Client A cache: X Client B cache: X

NFS Weak Consistency Protocol • Write-through caching: A write updates the server immediately •

NFS Weak Consistency Protocol • Write-through caching: A write updates the server immediately • Other clients poll the server periodically for changes • No guarantees for multiple writers

Andrew File System (AFS) • Developed at CMU • Design principles – Files are

Andrew File System (AFS) • Developed at CMU • Design principles – Files are cached on each client’s disks • NFS caches only in clients’ memory – Callbacks: The server records who has the copy of a file – Write-back cache on file close. The server then tells all clients that own an old copy. – Session semantics: Updates are only visible on close

NFS Summary + Simple and highly portable - May become inconsistent sometimes – Does

NFS Summary + Simple and highly portable - May become inconsistent sometimes – Does not happen very often

AFS Illustrated Server cache: X Client A Client B

AFS Illustrated Server cache: X Client A Client B

AFS Illustrated Server cache: X callback list of X client A read X Client

AFS Illustrated Server cache: X callback list of X client A read X Client B

AFS Illustrated Server cache: X callback list of X client A read X Client

AFS Illustrated Server cache: X callback list of X client A read X Client A cache: X read X Client B

AFS Illustrated Server cache: X callback list of X client A read X Client

AFS Illustrated Server cache: X callback list of X client A read X Client A cache: X Client B read X

AFS Illustrated Server cache: X callback list of X client A client B read

AFS Illustrated Server cache: X callback list of X client A client B read X Client A cache: X Client B read X

AFS Illustrated Server cache: X callback list of X client A client B read

AFS Illustrated Server cache: X callback list of X client A client B read X Client A cache: X Client B cache: X read X

AFS Illustrated Server cache: X Client A cache: X write X, X X Client

AFS Illustrated Server cache: X Client A cache: X write X, X X Client B cache: X

AFS Illustrated Server cache: X X X Client A cache: X close X Client

AFS Illustrated Server cache: X X X Client A cache: X close X Client B cache: X

AFS Illustrated Server cache: X X X Client A cache: X close X Client

AFS Illustrated Server cache: X X X Client A cache: X close X Client B cache: X

AFS Illustrated Server cache: X Client A cache: X Client B cache: X close

AFS Illustrated Server cache: X Client A cache: X Client B cache: X close X

AFS Illustrated Server cache: X X Client A cache: X Client B cache: X

AFS Illustrated Server cache: X X Client A cache: X Client B cache: X open X

AFS Illustrated Server cache: X X Client A cache: X Client B cache: X

AFS Illustrated Server cache: X X Client A cache: X Client B cache: X open X