lecture16

lecture16 - File Systems File systems provide applications...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
File Systems File systems provide applications with permanent storage. More than that theyorg anize and protect data, and provide a clean interface to allowmanipulation of that data. It’snoexaggeration to say that pro- viding a file system is one of the major services of general purpose operating systems, and less general ones as well. (Even the palm pilot has permanent storage). Files Afile is a persistent, hardware-independent, named, protected collection of bits and a collection of operations that can be executed on them. The access operations generally impose an order on the bits. The attributes attributes define what files are used for. Persistence implies that the bytes have a meaning that extends in time. Memory used in calculating intermediate results doesn’ thav e that attribute. One wouldn’ tstore the memory used in a computation in a file because it has no long-term use. Because the data in files has this long term significance, files are stored on more permanent media. These days, the most common medium is still magnetic disk, although several others are making bids. Some other media that can contain files are memory ,flash memory 1 ,tapes, CD-ROMS, and more esoteric media. Basically anything that can hold information permanently and be read by a computer has held a file system, or will eventually. By definition, files are largely medium-independent. The same operations are generally allowed on files regardless of the underlying storage medium. There are obvious exceptions - you can write to a CD- ROMatmost once, and there are obvious drawbacks to trying to move toabyte at the front of a tape to the back. In general, however, code that manipulates files on one medium will work on others. This savesalot of programmer time, as we’ll see. Finally ,file systems provide a way to name files. This is a seemingly simple function that turns out to be enormously powerful. 2 File systems provide ways to name files that span multiple media on the same machine (the UNIX®file system), loosely connected local area networks (the Network File System (NFS)) and evenglobal name spaces (the AndrewFile System (AFS)). Providing a name space outside the con- fines of memory addresses allows processes to share data and communicate. Because files are outside memory ,theyare also outside the protection of the memory protection sys- tem 3 .Asaresult, the file system has to impose ideas of user identity and related privileges on the data. The File Abstraction Although the idea of an abstract, named collection of bytes is easy enough to grasp, the Devil is in the details. Despite the fairly simple idea of what a file is, files on different operating systems can be remarkably different. We’ll discuss the variations in the file abstraction along the following axes: •N aming •D ata Structure and Access Patterns •F ile Types •A ttributes •O perations 1 Flash memory holds the data stored in it evenwhen the power is off. So does core memory ,but your gener- ation will only see that in museums.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 5

lecture16 - File Systems File systems provide applications...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online