Disks and I/O Hakan Uraz - File Organization 1

Size: px
Start display at page:

Download "Disks and I/O Hakan Uraz - File Organization 1"

Transcription

1 Disks and I/O 2006 Hakan Uraz - File Organization 1

2 Disk Drive 2006 Hakan Uraz - File Organization 2

3 Tracks and Sectors on Disk Surface 2006 Hakan Uraz - File Organization 3

4 A Set of Cylinders on Disk Drive 2006 Hakan Uraz - File Organization 4

5 Capacities Track capacity = number of sectors per track X bytes per sector Cylinder capacity = number of tracks per cylinder X track capacity Drive capacity = number of cylinders X cylinder capacity 2006 Hakan Uraz - File Organization 5

6 Example We want to store a file with fixedlength data records on a 300-megabyte small disk with the following characteristics: Number of bytes per sector = 512 Number of sectors per track = 40 Number of tracks per cylinder = 11 Number of cylinders = 1331 How many cylinders does the file require if each data record requires 256 bytes? 2006 Hakan Uraz - File Organization 6

7 Answer Since each sector can hold two records, the file requires 20000/2 = sectors. One cylinder can hold 40 X 11 = 440 sectors. So the number of cylinders required is 10000/440 = 22.7 cylinders. It may be that a disk drive with 22.7 cylinders of available space does not have 22.7 physically contiguous cylinders available. The file may be spread of hundreds of cylinders Hakan Uraz - File Organization 7

8 Organizing data on a disk Organizing tracks by sector, or Organizing tracks by user-defined blocks Hakan Uraz - File Organization 8

9 Organizing Tracks by Sector The physical placement of sectors The simplest view is that sectors are adjacent fixed-sized segments of a track that happen to hold a file. It is an adequate way to view a file logically, but it may not be a good way to store sectors physically Hakan Uraz - File Organization 9

10 Organizing Tracks by Sector The physical placement of sectors To read a series of sectors, you often cannot read adjacent sectors. It takes the disk controller some time to process the received information before it is ready to accept more. Consequently, we would be able to read only one sector per revolution of the disk Hakan Uraz - File Organization 10

11 Organizing Tracks by Sector Interleaving Hence sectors are interleaved, leaving an interval of several physical sectors between logically adjacent sectors. In the following figure, interleaving factor is 5. It takes five revolutions to read 32 sectors. An improvement over 32 revolutions. High performance disks can offer 1:1 interleaving Hakan Uraz - File Organization 11

12 Interleaving 2006 Hakan Uraz - File Organization 12

13 Organizing Tracks by Sector Clusters The view maintained by Operating System s file manager. A cluster is a fixed number of contiguous sectors. It is not always physically contiguous; the degree of physical contiguity is determined by the interleaving factor. All sectors in a cluster can be accessed without requiring additional seeks Hakan Uraz - File Organization 13

14 Organizing Tracks by Sector Clusters To view a file as a series of clusters and still maintain the sectored view, the file manager ties logical sectors to the physical clusters that they belong to by using a file allocation table (FAT). The FAT contains a list of all the clusters in a file, ordered according to the logical order of the sectors they contain. With each cluster entry in the FAT is an entry giving the physical location of the cluster Hakan Uraz - File Organization 14

15 Organizing Tracks by Sector 2006 Hakan Uraz - File Organization 15

16 Organizing Tracks by Sector Extents A further attempt to emphasize physical contiguity of sectors in a file, hence minimizing seeking even more. It may be possible to make a file consist entirely of contiguous clusters. Then, we say that the file consists of one extent: All of its sectors, tracks, and (if it is large enough) cylinders form one contiguous whole. If there is not enough contiguous space available to contain an entire file, the file is divided into two or more noncontiguous parts. Each part is an extent Hakan Uraz - File Organization 16

17 Organizing Tracks by Sector 2006 Hakan Uraz - File Organization 17

18 Organizing Tracks by Sector Fragmentation If the size of a sector is 512 bytes and the size of all records in a file is 300 bytes, there is no convenient fit between records and sectors. Solutions: 1. Store only one record per sector. 2. Allow records to span sectors, so the beginning of a record might be found in one sector and the end of it in another Hakan Uraz - File Organization 18

19 Organizing Tracks by Sector 2006 Hakan Uraz - File Organization 19

20 Organizing Tracks by Sector Fragmentation The first option has the advantage that any record can be retrieved by retrieving just one sector, but it has the disadvantage that it might leave an unused space within each sector called internal fragmentation. The second option has the advamtage that it loses no space from internal fragmentation, but it has the disadvantage that some records may be retrieved only by accessing two sectors Hakan Uraz - File Organization 20

21 Organizing Tracks by Sector Fragmentation The use of clusters may also result in internal fragmentation. When the number of bytes in a file is not an exact multiple of the cluster size, there will be internal fragmentation in the last extent of the file. A disk holding smaller files or files that are accessed only randomly would normally be set up with small clusters Large files processed sequentially are usually given large cluster sizes for performance Hakan Uraz - File Organization 21

22 Organizing Tracks by Block Sometimes disk tracks are not divided into sectors, but into integral numbers of user-defined blocks whose size can vary. The amount of data transferred in a single I/O operation can vary depending on the needs of the software designer, not the hardware. Blocks can normally be either fixed or variable in length, depending on the requirements of the file designer. As with sectors, blocks are often referred to as physical records Hakan Uraz - File Organization 22

23 Organizing Tracks by Block 2006 Hakan Uraz - File Organization 23

24 Organizing Tracks by Block A block organization does not present the sectorspanning and fragmentation problems of sectors because blocks can vary in size to fit the logical organization of the data. A block is usually organized to hold an integral number of logical records. The term blocking factor is used to indicate the number of records that are to be stored in each block in a file. Blocks are superior to sectors when it is desirable to have the physical allocation of space for records correspond to their logical organization Hakan Uraz - File Organization 24

25 Organizing Tracks by Block Each block of data is usually accompanied by one or more subblocks containing extra information about the data block. Count subblock contains (among other things) the number of bytes in the data block. There may be a key subblock containing the key for the last record in the data block. When key subblocks are used, a track can be searched by the disk controller for a block or record identified by a given key Hakan Uraz - File Organization 25

26 Organizing Tracks by Block 2006 Hakan Uraz - File Organization 26

27 Nondata Overhead Some of the overhead consists of information that is stored on the disk during preformatting. On sector-addressable disks, preformatting involves storing, at the beginning of each sector, such information as sector address, track address, and condition (whether the sector is usable or defective). Preformatting also involves placing gaps and synchronization marks between fields of information to help the read/write mechanism distinguish between them. These overhead is of no concern to programmer Hakan Uraz - File Organization 27

28 Nondata Overhead On a block-organized disk, some overhead is invisible some is visible to programmer. Since subblocks and interblock gaps have to be provided with every block, there is more overhead with blocks than with sectors. Also, since the number and sizes of blocks can vary from one application to another, the relative amount of space taken up by overhead can vary when block addressing is used Hakan Uraz - File Organization 28

29 Nondata Overhead Suppose we have a block-addressable disk drive with bytes per track, and the amount of space taken up by subblocks and interblock gaps is equivalent to 300 bytes per block. We want to store a file containing 100-byte records on the disk. How many records can be stored per track if the blocking factor is 10, or if it is 60? 2006 Hakan Uraz - File Organization 29

30 Nondata Overhead If there are byte records per block, each block holds 1000 bytes of data and uses or 1300 bytes of track space. The number of blocks which can fit on a byte track can be expressed as floor(20000/1300) = 15 So 15 blocks or 150 records can be stored per track. Note that we take the floor of the result because a block cannot span two tracks Hakan Uraz - File Organization 30

31 Nondata Overhead If there are byte records per block, each block holds 6000 bytes of data and uses 6300 bytes of track space. The number of blocks per track is floor(20000/6300) = 3 So 3 blocks, or 180 records, can be stored per track. Clearly, the larger blocking factor can lead to more efficient use of storage Hakan Uraz - File Organization 31

32 Nondata Overhead Larger blocking factors do not always lead to more efficient storage utilization. Since we can put only an integral number of blocks on a track, we lose some space at the end of the track. Here we have the internal fragmentation problem again within a track. The greater the block size, the greater potential amount of internal track fragmentation Hakan Uraz - File Organization 32

33 Nondata Overhead The use of blocks, rather than sectors introduces flexibility, since it lets the programmer determine how data are to be organized physically. As a disadvantage, this is a requirement for programmer and/or operating system. Also, the flexibility introduced precludes the synchronization of I/O operations with the physical movement of the disk. This means strategies such as sector interleaving cannot be used to improve performance Hakan Uraz - File Organization 33

34 The Cost of a Disk Access Three distinct physical operations: Seek time Rotational delay (rotational latency) Transfer time Hakan Uraz - File Organization 34

35 The Cost of a Disk Access Seek Time The time required to move the access arm to the correct cylinder. Seeking is likely to be more costly in a multiuser environment. Average seek time is the time to traverse 1/3 of the total number of cylinders Hakan Uraz - File Organization 35

36 The Cost of a Disk Access Rotational Delay The time it takes for the disk to rotate so the sector we want is under the read/write head. On average, the rotational delay is half a revolution Hakan Uraz - File Organization 36

37 The Cost of a Disk Access 2006 Hakan Uraz - File Organization 37

38 The Cost of a Disk Access Transfer Time Once the data we want is under the read/write head, it can be transferred. Transfer time = number of bytes transferred number of bytes on a track X rotation time 2006 Hakan Uraz - File Organization 38

39 The Cost of a Disk Access Let s compare the time it takes to access a file in sequence with the time it takes to access all of the records in the file randomly 2006 Hakan Uraz - File Organization 39

40 Specifications of disk drive Minimum seek time 6 msec Average seek time 18 msec Rotational delay 8.3 msec Maximum transfer rate 16.7 msec/track, or 1229 bytes/msec Bytes per sector 512 Sectors per track 40 Tracks per cylinder 11 Tracks per surface 1331 Interleave factor 1 Cluster size 8 sectors Smallest extent size 5 clusters 2006 Hakan Uraz - File Organization 40

41 The Cost of a Disk Access Smallest extent is 5 clusters. Space is allocated in one-track units. Let s read a 2048 Kbyte file that is divided into byte records. A cluster holds 16 records. There are 500 clusters to hold the file in 100 extents occupying 100 tracks Hakan Uraz - File Organization 41

42 To read sector by sector in sequence Average seek 18 msec Rotational delay 8.3 msec Read one track 16.7 msec Total 43 msec (Assume 100 tracks are randomly dispersed) Total time = 100 X 43 msec = 4.3 seconds 2006 Hakan Uraz - File Organization 42

43 To read same records with random access For each record Average seek 18 msec Rotational delay 8.3 msec Read one cluster (1/5 X 16.7) 3.3 msec Total 29.6 msec Total time = 8000 X 29.6 msec = seconds Hakan Uraz - File Organization 43

44 Disk as Bottleneck To speed up system, multiprogramming is used. Another technique is disk striping which involves splitting the parts of a file on several different drives, then letting the separate drives deliver data simultaneously. A RAM disk is a large part of RAM configured to simulate the behavior of a mechanical disk in every respect except speed and volatility Hakan Uraz - File Organization 44

45 Disk as Bottleneck A disk cache is a large block of RAM configured to contain pages of data from a disk. When data is requested from secondary memory, the file manager first looks into the disk cache if it contains the data. Only if cache does not contain, disk is used. Caches improve performance because of the programs locality of references Hakan Uraz - File Organization 45

46 A Journey of a Byte What happens when a program writes a byte to a file on a disk? What happens between the program and the disk? Suppose we want to append a byte representing the character P stored in a character variable c to a file named in the variable TEXT. From the program s point of view, the journey is represented by the statement WRITE(TEXT, c, 1); But the journey is longer than that Hakan Uraz - File Organization 46

47 A Journey of a Byte The WRITE() statement results in a call to the operating system (OS). OS File manager deals with files and I/O. File manager may be thought of layers of procedures. Each layer calls the one below. At the lowest level, the byte is actually written to disk Hakan Uraz - File Organization 47

48 2006 Hakan Uraz - File Organization 48

49 A Journey of a Byte Instead of sending the sector immediately to the disk, the file manager usually waits to see if it can accumulate more bytes going to the same sector before transmitting. Also when the file is closed, the output buffers are flushed to disk Hakan Uraz - File Organization 49

50 A Journey of a Byte The Byte Leaves RAM: The I/O Processor and Disk Controller Because of bottlenecks created by the differences in speed and data-path widths, our byte might have to wait for an external data path to become available. Because of speed differences, the CPU can transmit to several external devices simultaneously Hakan Uraz - File Organization 50

51 The I/O Processor A Journey of a Byte I/O Processor disassembles and assembles groups of bytes for transmission to/from devices. It takes the instructions from the OS but once it begins processing I/O, it runs independently. So, I/O processes and internal computing overlap. It can take data directly from RAM without the involvement of the CPU (direct memory access DMA). The file manager might tell the I/O processor that there is data in the buffer, how much data there is, and where it is to go on the disk. This info might be in the form of a little program that the OS constructs and I/O processor executes Hakan Uraz - File Organization 51

52 A Journey of a Byte The Disk Controller The I/O processor asks the disk controller if the disk drive is available. If not, our byte will have to wait in its buffer. The disk drive is instructed to move its head to the track and sector where to store our byte and its companions (a mechanical movement). Now, the I/O processor (or the controller) can send out the bytes, one at a time, to the drive where they are written on the disk surface Hakan Uraz - File Organization 52

53 Buffer Management Involves working with large chunks of data in RAM, so the number of disk accesses can be reduced. Consider what happens if a program is performing both input and output on one character at a time, and only one I/O buffer is available. To avoid such problems there is the need for several system buffers Hakan Uraz - File Organization 53

54 Buffer Management Even if a program transmits data in only one direction, the use of a single system I/O buffer can slow it down considerably. (The operation of reading a sector from a disk is extremely slow compared to RAM speed). So, we use more than one buffer and have the I/O system filling the next sector or block of data while the CPU is processing the current one Hakan Uraz - File Organization 54

55 Multiple Buffering Suppose that a I/O bound program is only writing to disk. If two buffers are used and I/O-CPU overlapping is permitted, the CPU can be filling one buffer while the contents of the other are being transmitted to disk. When both tasks are finished, the roles of the buffers can be exchanged. This technique is called double buffering. The idea of swapping system buffers to allow processing and I/O to overlap need not be restricted to two buffers Hakan Uraz - File Organization 55

56 Multiple Buffering 2006 Hakan Uraz - File Organization 56

57 Buffer Pooling When a system buffer is needed, it is taken from a pool of available buffers and used. When the system receives a request to read a certain sector or block, it looks to see if one of its buffers already contains that sector or block. If no buffer contains it, then the system finds from its pool of buffers one that is not currently in use and loads the sector or block into it Hakan Uraz - File Organization 57

58 Buffer Pooling Sevaral schemes are used to decide which buffer to take from a buffer pool. One generally effective strategy is to take from the pool that buffer that is least recently used (LRU). When a buffer is accessed, it is put on a least-recentlyused queue, so it is allowed to retain its data until all other less-recently used buffers have been accessed. LRU strategy is based on the assumption that a block of data that has been used recently is more likely to be needed in the near future than one that has been used less recently Hakan Uraz - File Organization 58

59 Buffers Move Mode and Locate Mode When data must always be copied from a system buffer to a program buffer (or vice versa), the amount of time to perform the move can be substantial. This way of handling buffered data is called move mode. There are two ways to avoid move mode. Both techniques are examples of the approach called locate mode. These are: The file manager performing I/O directly between disk and the program s data area. The file manager using system buffers to handle I/O, but provide the program with the locations, through the use of pointer variables, of the system buffers Hakan Uraz - File Organization 59

60 I/O in UNIX The topmost I/O layer in UNIX deals with data primarily in logical terms. This layer consists of processes that impose certain logical views on files. Processes include shell routines, user programs that operate on files and library routines. Below this layer is the UNIX kernel, which incorporates all the rest of the layers. The kernel views all I/O as operating on a sequence of bytes, so once we pass control to the kernel all assumptions about the logical view of a file are gone Hakan Uraz - File Organization 60

61 UNIX-Kernel Let s illustrate the journey of a byte through the kernel. Considers the system call such as write(fd, &c, 1); The routines that let processes communicate directly with the kernel make up the system call interface Hakan Uraz - File Organization 61

62 UNIX-Kernel The kernel I/O system begins by connecting the file descriptor (fd) in your program to some file or device in the filesystem. It does this by proceeding through a series of four tables: A file descriptor table. An open file table, with information about open files A file allocation table, which is part of a structure called an index node. A table of index nodes, with one entry for each file in use Hakan Uraz - File Organization 62

63 UNIX-Kernel The file descriptor table is owned by the process (your program). The open file table and index node tables are owned by the kernel. The index node itself is part of the filesystem Hakan Uraz - File Organization 63

64 UNIX-Kernel Every process has its own descriptor table Hakan Uraz - File Organization 64

65 UNIX-Kernel It is possible for several different processes to refer to the same open file table entry, so one process could read part of a file, another process could read the next part, and so forth. On the other hand, if the same file is opened by two separate open() statements, two separate entries are made in the table, and the two processes operate on the file quite independently Hakan Uraz - File Organization 65

66 UNIX-Kernel The information in the open file table is transitory. The kernel needs more information about the file itself. This information is found in an index node referred to as an inode Hakan Uraz - File Organization 66

67 UNIX-Kernel An inode is more permanent than an open file table s entry (called file structure). A file structure exists only while a file is open for access, but an inode exists as long as its corresponding file exists. So, inode is kept on disk with the file (though not adjacent to the file). When a file is opened, a copy of its inode is loaded into RAM where it is added to the inode table for rapid access Hakan Uraz - File Organization 67

68 UNIX-Linking File Names to Files All references to files begin with a directory. A directory is a small file that contains, for each file, a file name together with a pointer to the file s inode on disk. This pointer is called a hard link. When a file is opened, this hard link is used to bring the inode into RAM and to set up the corresponding entry in the open file table. It is possible for several file names to point to the same inode. A field in the inode tells how many hard links there are to the inode Hakan Uraz - File Organization 68

69 UNIX-Linking File Names to Files Another kind of link, called a soft link (or symbolic link) links a file name to another file name, rather than to an actual file. Instead of being a pointer to an inode, a soft link is a pathname of some file. Since a symbolic link does not point to an actual file, it can refer to a directory or even a file in a different file system Hakan Uraz - File Organization 69

70 UNIX-Normal Files, Special Files, and Sockets Normal files are block I/O files. Special files represent a stream of characters (e.g. the first three file descriptors in the descriptor table) Sockets are abstractions that serve as endpoints for interprocess communication Hakan Uraz - File Organization 70

71 UNIX-Block I/O The UNIX view of a block device is similar to disk. It is a randomly addressable array of fixed blocks. No other organization (such as clusters) was imposed on the placement of files on disk Hakan Uraz - File Organization 71

72 UNIX-Device Drivers They perform the actual I/O between the I/O buffer and the device. For block I/O, the device driver s job is to take a block from a buffer, destined for one of these physical blocks, and see that it gets deposited in the proper physical place on the device Hakan Uraz - File Organization 72

73 UNIX-The Kernel and Filesystems A filesystem includes the directory structure, the directories, ordinary files, and the inodes that describe the files. All parts of a filesystem reside on disk, rather than in RAM. These parts are brought into RAM by the kernel as needed. One advantage of keeping the filesystem and I/O system distinct is that we can have separate filesystems that are organized differently, perhaps on different devices, but are accesible by the same kernel Hakan Uraz - File Organization 73

1. What is the difference between primary storage and secondary storage?

1. What is the difference between primary storage and secondary storage? 1. What is the difference between primary storage and secondary storage? Primary Storage is - Limited - Volatile - Expensive - Fast (May be accessed directly from the CPU) - Retrieving a single character

More information

Operating Systems. Designed and Presented by Dr. Ayman Elshenawy Elsefy

Operating Systems. Designed and Presented by Dr. Ayman Elshenawy Elsefy Operating Systems Designed and Presented by Dr. Ayman Elshenawy Elsefy Dept. of Systems & Computer Eng.. AL-AZHAR University Website : eaymanelshenawy.wordpress.com Email : eaymanelshenawy@yahoo.com Reference

More information

File. File System Implementation. Operations. Permissions and Data Layout. Storing and Accessing File Data. Opening a File

File. File System Implementation. Operations. Permissions and Data Layout. Storing and Accessing File Data. Opening a File File File System Implementation Operating Systems Hebrew University Spring 2007 Sequence of bytes, with no structure as far as the operating system is concerned. The only operations are to read and write

More information

Chapter 11: Implementing File Systems. Operating System Concepts 8 th Edition,

Chapter 11: Implementing File Systems. Operating System Concepts 8 th Edition, Chapter 11: Implementing File Systems, Silberschatz, Galvin and Gagne 2009 Chapter 11: Implementing File Systems File-System Structure File-System Implementation Directory Implementation Allocation Methods

More information

Chapter 4 File Systems. Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc. All rights reserved

Chapter 4 File Systems. Tanenbaum, Modern Operating Systems 3 e, (c) 2008 Prentice-Hall, Inc. All rights reserved Chapter 4 File Systems File Systems The best way to store information: Store all information in virtual memory address space Use ordinary memory read/write to access information Not feasible: no enough

More information

I/O Management and Disk Scheduling. Chapter 11

I/O Management and Disk Scheduling. Chapter 11 I/O Management and Disk Scheduling Chapter 11 Categories of I/O Devices Human readable used to communicate with the user video display terminals keyboard mouse printer Categories of I/O Devices Machine

More information

File Systems. ECE 650 Systems Programming & Engineering Duke University, Spring 2018

File Systems. ECE 650 Systems Programming & Engineering Duke University, Spring 2018 File Systems ECE 650 Systems Programming & Engineering Duke University, Spring 2018 File Systems Abstract the interaction with important I/O devices Secondary storage (e.g. hard disks, flash drives) i.e.

More information

Chapter 11: File System Implementation. Objectives

Chapter 11: File System Implementation. Objectives Chapter 11: File System Implementation Objectives To describe the details of implementing local file systems and directory structures To describe the implementation of remote file systems To discuss block

More information

Secondary Storage (Chp. 5.4 disk hardware, Chp. 6 File Systems, Tanenbaum)

Secondary Storage (Chp. 5.4 disk hardware, Chp. 6 File Systems, Tanenbaum) Secondary Storage (Chp. 5.4 disk hardware, Chp. 6 File Systems, Tanenbaum) Secondary Stora Introduction Secondary storage is the non volatile repository for (both user and system) data and programs. As

More information

Operating Systems Design Exam 2 Review: Spring 2011

Operating Systems Design Exam 2 Review: Spring 2011 Operating Systems Design Exam 2 Review: Spring 2011 Paul Krzyzanowski pxk@cs.rutgers.edu 1 Question 1 CPU utilization tends to be lower when: a. There are more processes in memory. b. There are fewer processes

More information

Introduction. Secondary Storage. File concept. File attributes

Introduction. Secondary Storage. File concept. File attributes Introduction Secondary storage is the non-volatile repository for (both user and system) data and programs As (integral or separate) part of an operating system, the file system manages this information

More information

SMD149 - Operating Systems - File systems

SMD149 - Operating Systems - File systems SMD149 - Operating Systems - File systems Roland Parviainen November 21, 2005 1 / 59 Outline Overview Files, directories Data integrity Transaction based file systems 2 / 59 Files Overview Named collection

More information

CS 416: Opera-ng Systems Design March 23, 2012

CS 416: Opera-ng Systems Design March 23, 2012 Question 1 Operating Systems Design Exam 2 Review: Spring 2011 Paul Krzyzanowski pxk@cs.rutgers.edu CPU utilization tends to be lower when: a. There are more processes in memory. b. There are fewer processes

More information

CHAPTER 11: IMPLEMENTING FILE SYSTEMS (COMPACT) By I-Chen Lin Textbook: Operating System Concepts 9th Ed.

CHAPTER 11: IMPLEMENTING FILE SYSTEMS (COMPACT) By I-Chen Lin Textbook: Operating System Concepts 9th Ed. CHAPTER 11: IMPLEMENTING FILE SYSTEMS (COMPACT) By I-Chen Lin Textbook: Operating System Concepts 9th Ed. File-System Structure File structure Logical storage unit Collection of related information File

More information

File. File System Implementation. File Metadata. File System Implementation. Direct Memory Access Cont. Hardware background: Direct Memory Access

File. File System Implementation. File Metadata. File System Implementation. Direct Memory Access Cont. Hardware background: Direct Memory Access File File System Implementation Operating Systems Hebrew University Spring 2009 Sequence of bytes, with no structure as far as the operating system is concerned. The only operations are to read and write

More information

ECE 650 Systems Programming & Engineering. Spring 2018

ECE 650 Systems Programming & Engineering. Spring 2018 ECE 650 Systems Programming & Engineering Spring 2018 File Systems Tyler Bletsch Duke University Slides are adapted from Brian Rogers (Duke) File Systems Disks can do two things: read_block and write_block

More information

Chapter 3. Secondary Storage and System Software

Chapter 3. Secondary Storage and System Software Chapter 3. Secondary Storage and System Software Kim Joung-Joon Database Lab. jjkim9@db.konkuk.ac.kr Chapter Outline (1/2) 3.1 Disk 3.2 Magnetic Tape 3.3 Disk versus Tape 3.4 Introduction to CD-ROM 3.5

More information

File Management By : Kaushik Vaghani

File Management By : Kaushik Vaghani File Management By : Kaushik Vaghani File Concept Access Methods File Types File Operations Directory Structure File-System Structure File Management Directory Implementation (Linear List, Hash Table)

More information

Introduction to OS. File Management. MOS Ch. 4. Mahmoud El-Gayyar. Mahmoud El-Gayyar / Introduction to OS 1

Introduction to OS. File Management. MOS Ch. 4. Mahmoud El-Gayyar. Mahmoud El-Gayyar / Introduction to OS 1 Introduction to OS File Management MOS Ch. 4 Mahmoud El-Gayyar elgayyar@ci.suez.edu.eg Mahmoud El-Gayyar / Introduction to OS 1 File Management Objectives Provide I/O support for a variety of storage device

More information

e-pg Pathshala Subject: Computer Science Paper: Operating Systems Module 35: File Allocation Methods Module No: CS/OS/35 Quadrant 1 e-text

e-pg Pathshala Subject: Computer Science Paper: Operating Systems Module 35: File Allocation Methods Module No: CS/OS/35 Quadrant 1 e-text e-pg Pathshala Subject: Computer Science Paper: Operating Systems Module 35: File Allocation Methods Module No: CS/OS/35 Quadrant 1 e-text 35.1 Introduction File system is the most visible part of the

More information

Operating Systems. Operating Systems Professor Sina Meraji U of T

Operating Systems. Operating Systems Professor Sina Meraji U of T Operating Systems Operating Systems Professor Sina Meraji U of T How are file systems implemented? File system implementation Files and directories live on secondary storage Anything outside of primary

More information

Secondary Storage Devices: Magnetic Disks Optical Disks Floppy Disks Magnetic Tapes CENG 351 1

Secondary Storage Devices: Magnetic Disks Optical Disks Floppy Disks Magnetic Tapes CENG 351 1 Secondary Storage Devices: Magnetic Disks Optical Disks Floppy Disks Magnetic Tapes CENG 351 1 Secondary Storage Devices Two major types of secondary storage devices: 1. Direct Access Storage Devices (DASDs)

More information

Secondary Storage : Outline

Secondary Storage : Outline Secondary Storage : Outline! Magnetic Tapes! Disks Magnetic Tape "Sequential access "Compact "Easy to store and transport "Less expensive "Storing data off-line "Archival storage Organization of Data on

More information

Chapter 8: Virtual Memory. Operating System Concepts

Chapter 8: Virtual Memory. Operating System Concepts Chapter 8: Virtual Memory Silberschatz, Galvin and Gagne 2009 Chapter 8: Virtual Memory Background Demand Paging Copy-on-Write Page Replacement Allocation of Frames Thrashing Memory-Mapped Files Allocating

More information

Chapter 11. I/O Management and Disk Scheduling

Chapter 11. I/O Management and Disk Scheduling Operating System Chapter 11. I/O Management and Disk Scheduling Lynn Choi School of Electrical Engineering Categories of I/O Devices I/O devices can be grouped into 3 categories Human readable devices

More information

Chapter 11: File System Implementation

Chapter 11: File System Implementation Chapter 11: File System Implementation File System Structure File System Implementation Directory Implementation Allocation Methods Free-Space Management Efficiency and Performance Recovery Log-Structured

More information

Preview. Memory Management

Preview. Memory Management Preview Memory Management With Mono-Process With Multi-Processes Multi-process with Fixed Partitions Modeling Multiprogramming Swapping Memory Management with Bitmaps Memory Management with Free-List Virtual

More information

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

Background. 20: Distributed File Systems. DFS Structure. Naming and Transparency. Naming Structures. Naming Schemes Three Main Approaches Background 20: Distributed File Systems Last Modified: 12/4/2002 9:26:20 PM Distributed file system (DFS) a distributed implementation of the classical time-sharing model of a file system, where multiple

More information

Outlook. File-System Interface Allocation-Methods Free Space Management

Outlook. File-System Interface Allocation-Methods Free Space Management File System Outlook File-System Interface Allocation-Methods Free Space Management 2 File System Interface File Concept File system is the most visible part of an OS Files storing related data Directory

More information

CSE 380 Computer Operating Systems

CSE 380 Computer Operating Systems CSE 380 Computer Operating Systems Instructor: Insup Lee University of Pennsylvania Fall 2003 Lecture Note on Disk I/O 1 I/O Devices Storage devices Floppy, Magnetic disk, Magnetic tape, CD-ROM, DVD User

More information

Files. File Structure. File Systems. Structure Terms. File Management System. Chapter 12 File Management 12/6/2018

Files. File Structure. File Systems. Structure Terms. File Management System. Chapter 12 File Management 12/6/2018 Operating Systems: Internals and Design Principles Chapter 2 Management Ninth Edition By William Stallings s collections created by users The System is one of the most important parts of the OS to a user

More information

File Management. Chapter 12

File Management. Chapter 12 File Management Chapter 12 Files Used for: input to a program Program output saved for long-term storage Terms Used with Files Field basic element of data contains a single value characterized by its length

More information

UNIT 4 Device Management

UNIT 4 Device Management UNIT 4 Device Management (A) Device Function. (B) Device Characteristic. (C) Disk space Management. (D) Allocation and Disk scheduling Methods. [4.1] Device Management Functions The management of I/O devices

More information

Disks, Memories & Buffer Management

Disks, Memories & Buffer Management Disks, Memories & Buffer Management The two offices of memory are collection and distribution. - Samuel Johnson CS3223 - Storage 1 What does a DBMS Store? Relations Actual data Indexes Data structures

More information

CS3600 SYSTEMS AND NETWORKS

CS3600 SYSTEMS AND NETWORKS CS3600 SYSTEMS AND NETWORKS NORTHEASTERN UNIVERSITY Lecture 11: File System Implementation Prof. Alan Mislove (amislove@ccs.neu.edu) File-System Structure File structure Logical storage unit Collection

More information

CS370 Operating Systems

CS370 Operating Systems CS370 Operating Systems Colorado State University Yashwant K Malaiya Fall 2017 Lecture 24 File Systems Slides based on Text by Silberschatz, Galvin, Gagne Various sources 1 1 Questions from last time How

More information

Chapter 11: Implementing File-Systems

Chapter 11: Implementing File-Systems Chapter 11: Implementing File-Systems Chapter 11 File-System Implementation 11.1 File-System Structure 11.2 File-System Implementation 11.3 Directory Implementation 11.4 Allocation Methods 11.5 Free-Space

More information

CSC 553 Operating Systems

CSC 553 Operating Systems CSC 553 Operating Systems Lecture 12 - File Management Files Data collections created by users The File System is one of the most important parts of the OS to a user Desirable properties of files: Long-term

More information

DEPT OF ISE, NIT,RAICHUR Page 1

DEPT OF ISE, NIT,RAICHUR Page 1 1. Explain briefly the short history of file structure design. (4 M) (Dec/Jan 2016), (June/July 2015). Earlier, the file access was sequential, and the cost of access grew in direct proportion to the size

More information

Operating System Concepts

Operating System Concepts Chapter 9: Virtual-Memory Management 9.1 Silberschatz, Galvin and Gagne 2005 Chapter 9: Virtual Memory Background Demand Paging Copy-on-Write Page Replacement Allocation of Frames Thrashing Memory-Mapped

More information

Chapter 11: Implementing File

Chapter 11: Implementing File Chapter 11: Implementing File Systems Chapter 11: Implementing File Systems File-System Structure File-System Implementation Directory Implementation Allocation Methods Free-Space Management Efficiency

More information

CS5460: Operating Systems Lecture 20: File System Reliability

CS5460: Operating Systems Lecture 20: File System Reliability CS5460: Operating Systems Lecture 20: File System Reliability File System Optimizations Modern Historic Technique Disk buffer cache Aggregated disk I/O Prefetching Disk head scheduling Disk interleaving

More information

Chapter 9: Virtual Memory

Chapter 9: Virtual Memory Chapter 9: Virtual Memory Chapter 9: Virtual Memory 9.1 Background 9.2 Demand Paging 9.3 Copy-on-Write 9.4 Page Replacement 9.5 Allocation of Frames 9.6 Thrashing 9.7 Memory-Mapped Files 9.8 Allocating

More information

Mass Storage. 2. What are the difference between Primary storage and secondary storage devices? Primary Storage is Devices. Secondary Storage devices

Mass Storage. 2. What are the difference between Primary storage and secondary storage devices? Primary Storage is Devices. Secondary Storage devices 1. What are the logical organization of a file? Mass Storage 2. What are the difference between Primary storage and secondary storage devices? Primary Storage is Devices Secondary Storage devices - Limited,

More information

Chapter 11: Implementing File Systems. Operating System Concepts 9 9h Edition

Chapter 11: Implementing File Systems. Operating System Concepts 9 9h Edition Chapter 11: Implementing File Systems Operating System Concepts 9 9h Edition Silberschatz, Galvin and Gagne 2013 Chapter 11: Implementing File Systems File-System Structure File-System Implementation Directory

More information

Memory Management. Reading: Silberschatz chapter 9 Reading: Stallings. chapter 7 EEL 358

Memory Management. Reading: Silberschatz chapter 9 Reading: Stallings. chapter 7 EEL 358 Memory Management Reading: Silberschatz chapter 9 Reading: Stallings chapter 7 1 Outline Background Issues in Memory Management Logical Vs Physical address, MMU Dynamic Loading Memory Partitioning Placement

More information

CS370 Operating Systems

CS370 Operating Systems CS370 Operating Systems Colorado State University Yashwant K Malaiya Spring 2018 Lecture 22 File Systems Slides based on Text by Silberschatz, Galvin, Gagne Various sources 1 1 Disk Structure Disk can

More information

Addresses in the source program are generally symbolic. A compiler will typically bind these symbolic addresses to re-locatable addresses.

Addresses in the source program are generally symbolic. A compiler will typically bind these symbolic addresses to re-locatable addresses. 1 Memory Management Address Binding The normal procedures is to select one of the processes in the input queue and to load that process into memory. As the process executed, it accesses instructions and

More information

ECE519 Advanced Operating Systems

ECE519 Advanced Operating Systems IT 540 Operating Systems ECE519 Advanced Operating Systems Prof. Dr. Hasan Hüseyin BALIK (10 th Week) (Advanced) Operating Systems 10. Multiprocessor, Multicore and Real-Time Scheduling 10. Outline Multiprocessor

More information

Che-Wei Chang Department of Computer Science and Information Engineering, Chang Gung University

Che-Wei Chang Department of Computer Science and Information Engineering, Chang Gung University Che-Wei Chang chewei@mail.cgu.edu.tw Department of Computer Science and Information Engineering, Chang Gung University Chapter 10: File System Chapter 11: Implementing File-Systems Chapter 12: Mass-Storage

More information

Chapter 12: File System Implementation

Chapter 12: File System Implementation Chapter 12: File System Implementation Silberschatz, Galvin and Gagne 2013 Chapter 12: File System Implementation File-System Structure File-System Implementation Allocation Methods Free-Space Management

More information

CS6401- Operating System QUESTION BANK UNIT-IV

CS6401- Operating System QUESTION BANK UNIT-IV Part-A QUESTION BANK UNIT-IV 1. What is a File? A file is a named collection of related information that is recorded on secondary storage. A file contains either programs or data. A file has certain structure

More information

File System Implementation. Sunu Wibirama

File System Implementation. Sunu Wibirama File System Implementation Sunu Wibirama File-System Structure Outline File-System Implementation Directory Implementation Allocation Methods Free-Space Management Discussion File System Structure File

More information

Chapter-6. SUBJECT:- Operating System TOPICS:- I/O Management. Created by : - Sanjay Patel

Chapter-6. SUBJECT:- Operating System TOPICS:- I/O Management. Created by : - Sanjay Patel Chapter-6 SUBJECT:- Operating System TOPICS:- I/O Management Created by : - Sanjay Patel Disk Scheduling Algorithm 1) First-In-First-Out (FIFO) 2) Shortest Service Time First (SSTF) 3) SCAN 4) Circular-SCAN

More information

Virtual Memory. Chapter 8

Virtual Memory. Chapter 8 Virtual Memory 1 Chapter 8 Characteristics of Paging and Segmentation Memory references are dynamically translated into physical addresses at run time E.g., process may be swapped in and out of main memory

More information

Chapter 12 File-System Implementation

Chapter 12 File-System Implementation Chapter 12 File-System Implementation 1 Outline File-System Structure File-System Implementation Directory Implementation Allocation Methods Free-Space Management Efficiency and Performance Recovery Log-Structured

More information

OPERATING SYSTEM. Chapter 12: File System Implementation

OPERATING SYSTEM. Chapter 12: File System Implementation OPERATING SYSTEM Chapter 12: File System Implementation Chapter 12: File System Implementation File-System Structure File-System Implementation Directory Implementation Allocation Methods Free-Space Management

More information

Chapter 11: Implementing File Systems

Chapter 11: Implementing File Systems Silberschatz 1 Chapter 11: Implementing File Systems Thursday, November 08, 2007 9:55 PM File system = a system stores files on secondary storage. A disk may have more than one file system. Disk are divided

More information

CSE 153 Design of Operating Systems

CSE 153 Design of Operating Systems CSE 153 Design of Operating Systems Winter 2018 Lecture 22: File system optimizations and advanced topics There s more to filesystems J Standard Performance improvement techniques Alternative important

More information

Input Output (IO) Management

Input Output (IO) Management Input Output (IO) Management Prof. P.C.P. Bhatt P.C.P Bhatt OS/M5/V1/2004 1 Introduction Humans interact with machines by providing information through IO devices. Manyon-line services are availed through

More information

Database Systems. November 2, 2011 Lecture #7. topobo (mit)

Database Systems. November 2, 2011 Lecture #7. topobo (mit) Database Systems November 2, 2011 Lecture #7 1 topobo (mit) 1 Announcement Assignment #2 due today Assignment #3 out today & due on 11/16. Midterm exam in class next week. Cover Chapters 1, 2,

More information

V. File System. SGG9: chapter 11. Files, directories, sharing FS layers, partitions, allocations, free space. TDIU11: Operating Systems

V. File System. SGG9: chapter 11. Files, directories, sharing FS layers, partitions, allocations, free space. TDIU11: Operating Systems V. File System SGG9: chapter 11 Files, directories, sharing FS layers, partitions, allocations, free space TDIU11: Operating Systems Ahmed Rezine, Linköping University Copyright Notice: The lecture notes

More information

Storing Data: Disks and Files

Storing Data: Disks and Files Storing Data: Disks and Files Chapter 9 CSE 4411: Database Management Systems 1 Disks and Files DBMS stores information on ( 'hard ') disks. This has major implications for DBMS design! READ: transfer

More information

CS370 Operating Systems

CS370 Operating Systems CS370 Operating Systems Colorado State University Yashwant K Malaiya Fall 2017 Lecture 23 Virtual memory Slides based on Text by Silberschatz, Galvin, Gagne Various sources 1 1 FAQ Is a page replaces when

More information

OPERATING SYSTEM. Chapter 9: Virtual Memory

OPERATING SYSTEM. Chapter 9: Virtual Memory OPERATING SYSTEM Chapter 9: Virtual Memory Chapter 9: Virtual Memory Background Demand Paging Copy-on-Write Page Replacement Allocation of Frames Thrashing Memory-Mapped Files Allocating Kernel Memory

More information

First-In-First-Out (FIFO) Algorithm

First-In-First-Out (FIFO) Algorithm First-In-First-Out (FIFO) Algorithm Reference string: 7,0,1,2,0,3,0,4,2,3,0,3,0,3,2,1,2,0,1,7,0,1 3 frames (3 pages can be in memory at a time per process) 15 page faults Can vary by reference string:

More information

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

EI 338: Computer Systems Engineering (Operating Systems & Computer Architecture) EI 338: Computer Systems Engineering (Operating Systems & Computer Architecture) Dept. of Computer Science & Engineering Chentao Wu wuct@cs.sjtu.edu.cn Download lectures ftp://public.sjtu.edu.cn User:

More information

Memory Management. q Basic memory management q Swapping q Kernel memory allocation q Next Time: Virtual memory

Memory Management. q Basic memory management q Swapping q Kernel memory allocation q Next Time: Virtual memory Memory Management q Basic memory management q Swapping q Kernel memory allocation q Next Time: Virtual memory Memory management Ideal memory for a programmer large, fast, nonvolatile and cheap not an option

More information

Chapter 5. File and Memory Management

Chapter 5. File and Memory Management K. K. Wagh Polytechnic, Nashik Department: Information Technology Class: TYIF Sem: 5G System Subject: Operating Name of Staff: Suyog S.Dhoot Chapter 5. File and Memory Management A. Define file and explain

More information

MODULE 4. FILE SYSTEM AND SECONDARY STORAGE

MODULE 4. FILE SYSTEM AND SECONDARY STORAGE This document can be downloaded from www.chetanahegde.in with most recent updates. 1 MODULE 4. FILE SYSTEM AND SECONDARY STORAGE File system provides the mechanism for storage of data and access to data

More information

Lecture 9. I/O Management and Disk Scheduling Algorithms

Lecture 9. I/O Management and Disk Scheduling Algorithms Lecture 9 I/O Management and Disk Scheduling Algorithms 1 Lecture Contents 1. I/O Devices 2. Operating System Design Issues 3. Disk Scheduling Algorithms 4. RAID (Redundant Array of Independent Disks)

More information

Reducing Hit Times. Critical Influence on cycle-time or CPI. small is always faster and can be put on chip

Reducing Hit Times. Critical Influence on cycle-time or CPI. small is always faster and can be put on chip Reducing Hit Times Critical Influence on cycle-time or CPI Keep L1 small and simple small is always faster and can be put on chip interesting compromise is to keep the tags on chip and the block data off

More information

File System Implementation

File System Implementation File System Implementation Last modified: 16.05.2017 1 File-System Structure Virtual File System and FUSE Directory Implementation Allocation Methods Free-Space Management Efficiency and Performance. Buffering

More information

MEMORY MANAGEMENT/1 CS 409, FALL 2013

MEMORY MANAGEMENT/1 CS 409, FALL 2013 MEMORY MANAGEMENT Requirements: Relocation (to different memory areas) Protection (run time, usually implemented together with relocation) Sharing (and also protection) Logical organization Physical organization

More information

Introduction Disks RAID Tertiary storage. Mass Storage. CMSC 420, York College. November 21, 2006

Introduction Disks RAID Tertiary storage. Mass Storage. CMSC 420, York College. November 21, 2006 November 21, 2006 The memory hierarchy Red = Level Access time Capacity Features Registers nanoseconds 100s of bytes fixed Cache nanoseconds 1-2 MB fixed RAM nanoseconds MBs to GBs expandable Disk milliseconds

More information

File System Internals. Jo, Heeseung

File System Internals. Jo, Heeseung File System Internals Jo, Heeseung Today's Topics File system implementation File descriptor table, File table Virtual file system File system design issues Directory implementation: filename -> metadata

More information

Disk Scheduling COMPSCI 386

Disk Scheduling COMPSCI 386 Disk Scheduling COMPSCI 386 Topics Disk Structure (9.1 9.2) Disk Scheduling (9.4) Allocation Methods (11.4) Free Space Management (11.5) Hard Disk Platter diameter ranges from 1.8 to 3.5 inches. Both sides

More information

UNIX File Systems. How UNIX Organizes and Accesses Files on Disk

UNIX File Systems. How UNIX Organizes and Accesses Files on Disk UNIX File Systems How UNIX Organizes and Accesses Files on Disk Why File Systems File system is a service which supports an abstract representation of the secondary storage to the OS A file system organizes

More information

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

Chapter 17: Distributed-File Systems. Operating System Concepts 8 th Edition, Chapter 17: Distributed-File Systems, Silberschatz, Galvin and Gagne 2009 Chapter 17 Distributed-File Systems Background Naming and Transparency Remote File Access Stateful versus Stateless Service File

More information

FILE SYSTEMS. CS124 Operating Systems Winter , Lecture 23

FILE SYSTEMS. CS124 Operating Systems Winter , Lecture 23 FILE SYSTEMS CS124 Operating Systems Winter 2015-2016, Lecture 23 2 Persistent Storage All programs require some form of persistent storage that lasts beyond the lifetime of an individual process Most

More information

Operating Systems Memory Management. Mathieu Delalandre University of Tours, Tours city, France

Operating Systems Memory Management. Mathieu Delalandre University of Tours, Tours city, France Operating Systems Memory Management Mathieu Delalandre University of Tours, Tours city, France mathieu.delalandre@univ-tours.fr 1 Operating Systems Memory Management 1. Introduction 2. Contiguous memory

More information

Directory Structure and File Allocation Methods

Directory Structure and File Allocation Methods ISSN:0975-9646 Mandeep Kaur et al, / (IJCSIT) International Journal of Computer Science and Information Technologies, Vol. 7 (2), 2016, 577-582 Directory Structure and ile Allocation Methods Mandeep Kaur,

More information

ICS Principles of Operating Systems

ICS Principles of Operating Systems ICS 143 - Principles of Operating Systems Lectures 17-20 - FileSystem Interface and Implementation Prof. Ardalan Amiri Sani Prof. Nalini Venkatasubramanian ardalan@ics.uci.edu nalini@ics.uci.edu Outline

More information

Operating Systems. Lecture File system implementation. Master of Computer Science PUF - Hồ Chí Minh 2016/2017

Operating Systems. Lecture File system implementation. Master of Computer Science PUF - Hồ Chí Minh 2016/2017 Operating Systems Lecture 7.2 - File system implementation Adrien Krähenbühl Master of Computer Science PUF - Hồ Chí Minh 2016/2017 Design FAT or indexed allocation? UFS, FFS & Ext2 Journaling with Ext3

More information

Virtual Memory Outline

Virtual Memory Outline Virtual Memory Outline Background Demand Paging Copy-on-Write Page Replacement Allocation of Frames Thrashing Memory-Mapped Files Allocating Kernel Memory Other Considerations Operating-System Examples

More information

Operating Systems Unit 6. Memory Management

Operating Systems Unit 6. Memory Management Unit 6 Memory Management Structure 6.1 Introduction Objectives 6.2 Logical versus Physical Address Space 6.3 Swapping 6.4 Contiguous Allocation Single partition Allocation Multiple Partition Allocation

More information

File system internals Tanenbaum, Chapter 4. COMP3231 Operating Systems

File system internals Tanenbaum, Chapter 4. COMP3231 Operating Systems File system internals Tanenbaum, Chapter 4 COMP3231 Operating Systems Architecture of the OS storage stack Application File system: Hides physical location of data on the disk Exposes: directory hierarchy,

More information

UNIT III MEMORY MANAGEMENT

UNIT III MEMORY MANAGEMENT UNIT III MEMORY MANAGEMENT TOPICS TO BE COVERED 3.1 Memory management 3.2 Contiguous allocation i Partitioned memory allocation ii Fixed & variable partitioning iii Swapping iv Relocation v Protection

More information

L9: Storage Manager Physical Data Organization

L9: Storage Manager Physical Data Organization L9: Storage Manager Physical Data Organization Disks and files Record and file organization Indexing Tree-based index: B+-tree Hash-based index c.f. Fig 1.3 in [RG] and Fig 2.3 in [EN] Functional Components

More information

Storing and Retrieving Data. Storing Data: Disks and Files. Solution 1: Techniques for making disks faster. Disks. Why Not Store Everything in Tapes?

Storing and Retrieving Data. Storing Data: Disks and Files. Solution 1: Techniques for making disks faster. Disks. Why Not Store Everything in Tapes? Storing and Retrieving Storing : Disks and Files Chapter 9 base Management Systems need to: Store large volumes of data Store data reliably (so that data is not lost!) Retrieve data efficiently Alternatives

More information

The Berkeley File System. The Original File System. Background. Why is the bandwidth low?

The Berkeley File System. The Original File System. Background. Why is the bandwidth low? The Berkeley File System The Original File System Background The original UNIX file system was implemented on a PDP-11. All data transports used 512 byte blocks. File system I/O was buffered by the kernel.

More information

Operating-System Structures

Operating-System Structures Operating-System Structures System Components Operating System Services System Calls System Programs System Structure System Design and Implementation System Generation 1 Common System Components Process

More information

Chapter 1 Disk Storage, Basic File Structures, and Hashing.

Chapter 1 Disk Storage, Basic File Structures, and Hashing. Chapter 1 Disk Storage, Basic File Structures, and Hashing. Adapted from the slides of Fundamentals of Database Systems (Elmasri et al., 2003) 1 Chapter Outline Disk Storage Devices Files of Records Operations

More information

Chapter 13 Disk Storage, Basic File Structures, and Hashing.

Chapter 13 Disk Storage, Basic File Structures, and Hashing. Chapter 13 Disk Storage, Basic File Structures, and Hashing. Copyright 2004 Pearson Education, Inc. Chapter Outline Disk Storage Devices Files of Records Operations on Files Unordered Files Ordered Files

More information

Chapter 11 I/O Management and Disk Scheduling

Chapter 11 I/O Management and Disk Scheduling Operating Systems: Internals and Design Principles, 6/E William Stallings Chapter 11 I/O Management and Disk Scheduling Patricia Roy Manatee Community College, Venice, FL 2008, Prentice Hall 1 2 Differences

More information

Operating Systems CMPSC 473. File System Implementation April 1, Lecture 19 Instructor: Trent Jaeger

Operating Systems CMPSC 473. File System Implementation April 1, Lecture 19 Instructor: Trent Jaeger Operating Systems CMPSC 473 File System Implementation April 1, 2008 - Lecture 19 Instructor: Trent Jaeger Last class: File System Interface Today: File System Implementation Disks as Secondary Store What

More information

Virtual Memory. Reading. Sections 5.4, 5.5, 5.6, 5.8, 5.10 (2) Lecture notes from MKP and S. Yalamanchili

Virtual Memory. Reading. Sections 5.4, 5.5, 5.6, 5.8, 5.10 (2) Lecture notes from MKP and S. Yalamanchili Virtual Memory Lecture notes from MKP and S. Yalamanchili Sections 5.4, 5.5, 5.6, 5.8, 5.10 Reading (2) 1 The Memory Hierarchy ALU registers Cache Memory Memory Memory Managed by the compiler Memory Managed

More information

19 File Structure, Disk Scheduling

19 File Structure, Disk Scheduling 88 19 File Structure, Disk Scheduling Readings for this topic: Silberschatz et al., Chapters 10 11. File: a named collection of bytes stored on disk. From the OS standpoint, the file consists of a bunch

More information

Page 1. Recap: File System Goals" Recap: Linked Allocation"

Page 1. Recap: File System Goals Recap: Linked Allocation Recap: File System Goals" CS162 Operating Systems and Systems Programming Lecture 14 File Systems (cont d), Key Value Storage Systems" Maximize sequential performance Efiicient random access to file Easy

More information

CS307: Operating Systems

CS307: Operating Systems CS307: Operating Systems Chentao Wu 吴晨涛 Associate Professor Dept. of Computer Science and Engineering Shanghai Jiao Tong University SEIEE Building 3-513 wuct@cs.sjtu.edu.cn Download Lectures ftp://public.sjtu.edu.cn

More information