Class Note for CMPSCI 377 at UMass(56)
Class Note for CMPSCI 377 at UMass(56)
Popular in Course
Popular in Department
This 5 page Class Notes was uploaded by an elite notetaker on Friday February 6, 2015. The Class Notes belongs to a course at University of Massachusetts taught by a professor in Fall. Since its upload, it has received 12 views.
Reviews for Class Note for CMPSCI 377 at UMass(56)
Report this Material
What is Karma?
Karma is the currency of StudySoup.
You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!
Date Created: 02/06/15
CMPSCI 377 Operating Systems Fall 2005 Lecture 22 December 8 Lecturer Emery Berger Scribes Billy Dean and Zeid Rustm Last time Distributed Computing Today we re going to learn about Distributed File Systems 0 Remote File Access 0 Remote Caching 0 Network File Systems 0 Servers With state and Without replication 221 Distributed File Systems 2211 Remote File Access When les are accessed remotely7 rst the local system calls to get the remote le have to be changed into RPCs Remote Procedure Calls Remote Caching on a Local Disk 0 Reduces access time o Safe if a node fails o Hard to keep consistent local copy Remote Caching on Local Memory 0 Quick access time o Works Without a disk 0 Hard to keep consistent copy in memory 0 Power must be constant or data will be lost 222 Cache update policies Writethrough o Reliable 221 222 Lecture 22 December 8 o Low performance Writeback o Quick o Reduces network traf c 0 Users machine crashes7 causing data loss Cache consistency Client initiated consistency checks the consistency at every le access or at given intervals Server initiated consistency checks the consistency on a timer 0 Server detects con icts and invalidates the cache 0 Server needs to know which clients have cached which parts of the les 0 Server also needs to know which clients are readers and which are writers 223 Network File Systems De nes a set of Remote Procedure Call operations for remote access to les 1 Directory search7 read directory entries 2 Manipulating links and directories 3i Accessing le attributes 4 ReadWrite les NFS changes all requests into RPCs o NFS is good because it doesnt rely on all nodes being the same 0 However it is not consistent o Everything is done remotely7 therefore 0 It is 10 to 100 times slower than local procedure calls 0 Caching is bad as well because its all done through RPCi Big Four round trips of RFC are required for creating a new le Tip ln Linux7 the tmp directory is mounted locallyi So you can copy les you want to compile into there rst to get faster compilesi Sun7s NFS o The standard for UNIX Lecture 22 December 8 223 0 Intended for LANs 0 Not designed to run on the Internets scale Nodes can be clients and servers 0 Windows uses SombaSombaFSi 224 Advanced File Systems 0 Motivation and Review 0 Journaling 0 Log structured le systems Servers have special needs that the default FS 77ext277 doesnt support well 0 Large harddisk partitions 0 Quick crash recovery takes hours in ext2 o HighPerformance lO Does not scale well with the number of les 0 Storing thousands of files7 terabytes of data 2241 Blocks and Fragmentation 0 Logical Block smallest unit of storage allocated by the FS 0 Internal fragmentation happens when a le does not ll block completelyi Ext le10kb7 block8kb7 wastes 6k 0 External fragmentation happens when the logical blocks of a le are scattered This causes poor performance 2242 Review Organization 0 Extent maps for where les are stored o Contiguous blocks Triple leOffSet StartingBlockNumber7 Length File offset consists of an offset of extents rst block for le start Start block number First block in extent Length Number of blocks in extent lnode Stores information about le eg permissions7 types of links7 direct and indirect pointers7 etc Metadata 77ATime77 of le last time it was accessed Metadata updates 224 Lecture 22 December 8 0 Lots being updated 0 Scattered on disk slow and nonatomic Note Making lnodes bigger or adding more indirection will give you bigger le capacity7 but indirection requires too much hopping 2243 Repairing File System Inconsistency Unix7s command fka is a FS check It detects and repairs structural problems7 etc by marching though the entire disk looking for faults in all the Metadata It is run after power outages etc But 1 It is SLOW 2 It might not work The main problem We have nonatomic writes which then have to recover A solution 2244 Journaling File Systems 0 Automatically write all planned transactions into a log 0 Recovery in JFS Some updates are fully committed to le system7 nd journal entries7 replay the actions Journaling is great for Metadata l Fast 2 Guarantees consistency 3 Doesn7t guarantee zero data loss 2245 Logstructured File System 0 Preserves data integrity 0 Performance Schedules periodic compaction7 places lnode map to keep track of all locations You roll back to the last lnode map if something happens Examples 77Sprite77 LFS7 ReiserFS and X3 File systems Data is safe and it is faster 0 Outperforms UNIX FS for small writes and matches it for reads and large writes o Utilizes 70 percent of disk bandwidth even with the overhead of segment cleaning included Lecture 22 December 8 225 LFS structure 0 lnode maps maintain the location of data directories etc o Segments large free extents for Writing new data LFS extends journaling to data hardware RAID can do this too though Checkpoints rollforwards are part of this 0 Traditional FSs have integrity problems but that is solved by Journalingl Journaling is o Fast Stable
Are you sure you want to buy this material for
You're already Subscribed!
Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'