欢迎来到天天文库
浏览记录
ID:6003872
大小:1.20 MB
页数:38页
时间:2017-11-15
《hyz-os-2013-磁盘设备管理》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、113六月2021北京交通大学计算机学院何永忠操作系统(A)北京交通大学计算机学院何永忠副教授第五章:设备管理第五章设备管理5.1I/O系统组成5.2I/O控制方式5.3设备管理目标、功能及结构5.4缓冲管理5.5设备分配5.6设备处理5.7磁盘存储器管理5.7磁盘存储器管理5.7.1磁盘性能简述5.7.2磁盘调度5.7.3磁盘高速缓冲5.7.4提高磁盘I/O速度的其它方法5.7.5廉价磁盘冗余阵列HardDiskDrives(HDDs)IBM/HitachiMicrodriveWesternDigitalDrivehttp://www.storagereview.
2、com/guide/Read/WriteHeadSideViewIBMPersonalComputer/AT(1986)30MBharddisk-$50030-40msseektime0.7-1MB/s(est.)磁盘的类型硬盘和软盘、单片盘和多片盘固定头磁盘在每条磁道上都有一个读写磁头,所有磁头装在一刚性磁臂上,通过这些磁臂可访问所有的磁道,并进行并行读写,能有效提高磁盘I/O速度,这种结构主要用于大容量磁盘活动头(移动头)磁盘每个盘面仅配有一个读写磁头,也被装入磁臂中,为了能访问该盘面上的所有磁道,该磁头必须能够移动和进行寻道;移动头磁盘结构简单,但只能进行串行
3、读写故而I/O速度较慢,多用于中小型磁盘设备中PropertiesofaMagneticHardDiskPropertiesIndependentlyaddressableelement:sectorOSalwaystransfersgroupsofsectorstogether—“blocks”Adiskcanaccessdirectlyanygivenblockeithersequentiallyorrandomly.Typicalnumbers(dependingonthedisksize):500tomorethan20,000trackspersurfac
4、e32to800sectorspertrackZonedbitrecordingConstantbitdensity:morebits(sectors)onoutertracksApple][gs/oldMacs:speedvarieswithtracklocationTrackSectorPlatters数据的组织和格式基本数据组织层次盘片([盘面]):磁道:扇区(盘块)GAP1扇区0#物理扇区1#物理扇区IDField0GAP2GAP3DataField0GAP1IDField1GAP2GAP3DataField1SynchByteTrack#Sector#He
5、ad#CRCSynchByteDataCRC17B7B41B515B20B17B7B41B515B20B1B2B1B1B2B1B512B2BMagneticDiskCharacteristicCylinder:allthetracksundertheheadatagivenpointonallsurfacesRead/write:three-stageprocess:Seektime:positionthehead/armoverthepropertrack(intopropercylinder)Rotationallatency:waitforthedesire
6、dsectortorotateundertheread/writeheadTransfertime:transferablockofbits(sector)undertheread-writeheadDiskLatency=QueuingTime+Controllertime+SeekTime+RotationTime+XferTimeHighestBandwidth:TransferlargegroupofblockssequentiallyfromonetrackSectorTrackCylinderHeadPlatterSoftwareQueue(Dev
7、iceDriver)HardwareControllerMediaTime(Seek+Rot+Xfer)RequestResult移动头磁盘访问时间构成寻道时间Ts把磁臂(磁头)从当前位置移动到指定磁道上所经历的时间Ts=m×n+s旋转延迟时间Tr指定扇区旋转到磁头下面所经历的时间Tr=1/2r数据传输时间Tt把数据从磁盘读出或向磁盘写入数据所经历的时间Tt=bytes/(r×bytesPerTrack)访问时间中,数据传输时间所占比例相当小,而寻道时间和旋转延迟时间基本上均与所读写的数据量无关,所以适当地集中数据传输(不要太零散)将有利于提高传输效率Typic
此文档下载收益归作者所有