ImageVerifierCode 换一换
格式:PPT , 页数:31 ,大小:206KB ,
资源ID:378274      下载积分:2000 积分
快捷下载
登录下载
邮箱/手机:
温馨提示:
如需开发票,请勿充值!快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝扫码支付 微信扫码支付   
注意:如需开发票,请勿充值!
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【http://www.mydoc123.com/d-378274.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(AN IMPLEMENTATION OF ALOG-STRUCTURED FILE .ppt)为本站会员(terrorscript155)主动上传,麦多课文库仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知麦多课文库(发送邮件至master@mydoc123.com或直接QQ联系客服),我们立即给予删除!

AN IMPLEMENTATION OF ALOG-STRUCTURED FILE .ppt

1、AN IMPLEMENTATION OF A LOG-STRUCTURED FILE SYSTEM FOR UNIX,Margo Seltzer, Harvard U. Keith Bostic, U. C. Berkeley Marshall Kirk McKusick, U. C. Berkeley Carl Staelin, HP Labs,Overview,Paper presents a redesign and implementation of the Sprite LFS BSD-LFS is Faster than conventional UNIX FFS (the “fa

2、st” file system of the early 80s) Not as fast as an enhanced version of FFS with read and write clustering,Historical Perspective,Early UNIX FS used small block sizes and did not try to optimize block placement The UNIX FFS Increased block sizes Added cylinder groups Incorporated rotational disk pos

3、itioning to reduce delays when accessing sequential blocks,Limitations of FFS (I),Synchronous file deletion and creation Makes file system recoverable after a crash Same result can be achieved through NVRAM hardware or logging software,Limitations of FFS (II),Seek times between I/O requests for diff

4、erent files Has most impact on performance whenever vast majority of files are small FFS does not address the problem,Log-Structured File Systems,Attempt to address both limitations of FFS Store all data in a single, continuous log Optimized for All writes Reading files written in their entirety ove

5、r a short period of time Accessing files that were created or modified at the same time,General Organization,Disk is partitioned into segments Writes are always sequential within a segment Segment cleaner maintains a pool of empty (“clean”) segments through disk compaction “Live” data existing in a

6、a set of segments are regrouped in a smaller subset of segments,Overview,LFS Data Structures,Superblock: Same function as one used by FFS I-node map: Maps i-node numbers into disk addresses Segment usage tables: Show number of live bytes in a segment and last modification time Checkpoints: Created e

7、very time system does a sync(),Limitations of Sprite LFS,Recovery does not verify the consistency of the file system directory structure LFS consumes “excessive amounts” of main memory by 1993 standards Write requests are successful even if there is insufficient disk space Segment validation is hard

8、ware dependent All file systems use a single cleaner and a single cleaning policy No measure of the cleaner overhead,Recovery (I),Two major aspects Bringing the file system to a physically consistent state Verifying the logical structure of the file system FFS achieves both goals through fsck Rebuil

9、ds the whole file system Verifies the directory structure and all block pointers,Recovery (II),Sprite LFS uses a two-step recovery process: Initializes first all the file structures from the most recent checkpoint “Roll forward” to incorporate all subsequent modifications Done by reading each segmen

10、t in time order after the last checkpoint,Recovery (III),Standard LFS recovery does not verify the directory structure Weakness to be addressed in BSD-LFS,Memory Consumption,Sprite LFS reserves “large amounts” of main memory including four half-megabyte segments and many buffers BSD-LFS: Does not us

11、e special staging buffers Does not reserve two read-only segments that can be reclaimed without any I/O Implements cleaner as a user-level process,Block Accounting,Sprite LFS maintained a count of disk blocks available for physical writing Blocks written to the cache but not written to disk do not a

12、ffect that count What if a block is “successfully” written to the cache but the disk becomes full before the blocks are actually written? BSD-LFS keeps a separate count of disk blocks that are not yet committed to any dirty block in the cache,Segment Structure (I),Sprint LFS places segment summary b

13、locks at the end of the segment Write containing the segment summary validates the whole segment Makes two incorrect assumptions Controller will not reorder write requests Disk will always write the contents of a buffer in the order presented,Segment Structure (II),BSD-LFS Does not make these assump

14、tions Segment blocks can be written in any order Segment summary is in front of each partial segment and contains a checksum of four bytes of every block in the partial segment Partial segments constitute the atomic recovery units of BDS-LFS,File System Verification,BSD-LFS offers two recovery strat

15、egies Quick roll forward from last checkpoint Complete consistency check of the file system Recovers lost or corrupted data Same functionality as FFS fsck() Takes a long time to run Can be run in the background,The Cleaner,BSD-LFS makes it possible to implement the cleaner as a user process Allows f

16、or multiple cleaning policies Makes it easier to experiment with new policies,Implementation Issues,BSD-LFS uses on-disk data structures that are nearly identical to those used by FFS Existing performance tools can continue to function with only minor modification Makes system easier to implement an

17、d maintain Two type of operations Vfs operations affect the whole file system Vnode operations affect individual files,More Implementation Issues,BSD-LFS does not implement block fragments Less needed block sizes could be smaller Still want large blocks to keep metadata to data ratio low BSD-LFS sho

18、uld (but does not yet) allocate progressively larger blocks.,The Buffer Cache (I),Had to modify the FFS buffer cache Cannot assume that cache blocks can be flushed one at a time Would destroy any performance advantage of LFS LFS may need extra memory to write modified metadata and partial segment su

19、mmary blocks,The Buffer Cache (II),Cache blocks do not have a disk address until they are written to the disk Violates assumption that all blocks have disk addresses Cannot use disk address to access indirect blocks BSD-LFS incorporates metadata block numbering (negative values),The IFILE,Sprite-LFS

20、 maintained the i-node map and segment usage table as kernel data structures written to disk at checkpoint time BSD-LFS places both data structures in a read-only file visible in the file system Allows unlimited number of i-nodes Cleaner can be migrated into user space I-node map also contains a lis

21、t of free i-nodes,Directory Operations (I),BSD-LFS does not retain synchronous behavior of directory operations (create, link, mkdir, ) Sprite-LFS maintains ordering of directory operations by maintaining a directory operation log inside the file system log Before any directory updates are written t

22、o disk, it writes a log entry describing that operation,Directory Operations (II),BSD-LFS has a unit of atomicity the partial segment It does not have a mechanism that guarantees that all i-nodes involved in a directory operation will fit into a single partial segment BSD-LFS allows operations to sp

23、an partial segments,Directory Operations (III),Introduces a new recovery restriction Cannot roll forward a partial segment that has an unfinished directory operation if the partial segment that completes the directory operation did not make it to disk (segment batching),COMPARISON,BSD-LFS was found

24、to perform Better to the 4BSD FFS in a variety of benchmarks Not significantly worse than FFS in any test EFS, a version of FFS with read and write clustering was found to provide comparable and sometimes superior performance to BSD- LFS.,EFS,Extended version of FFS Provides extent-based file system

25、 behavior Parameter maxcontig specifies how many logically sequential disk blocks should be allocated contiguously Large maxcontig is same as track allocation EFS accumulates sequential dirty buffers in the cache before writing them as a cluster,Multi-user Andrew Benchmark,We measure execution times

26、 LFS performs well in phases 1 and 2 (mostly writes) and poorly in phase 5 (random I/O),CONCLUSIONS,A LFS operates best when it can write out many dirty buffers at once Requires more buffer space in main memory Delayed allocation of BSD-LFS complicates accounting of available free space Issue was not correctly handled by Sprite-LFSCleaner might sometimes consumes more disk space than it frees Must reserve additional disk space,

copyright@ 2008-2019 麦多课文库(www.mydoc123.com)网站版权所有
备案/许可证编号:苏ICP备17064731号-1