0% found this document useful (0 votes)
1K views16 pages

Directory and Disk Structure: Presented by

The document discusses directory and disk structure. It can be summarized as follows: 1. A directory structure is a collection of nodes containing information about all files and directories, organized in a tree structure. Disks can be divided into partitions which can contain file systems. 2. Disk partitions can be formatted with different file systems like UFS or ZFS. Each file system contains metadata about the files and directories in the device directory. 3. In addition to general file systems, there are special purpose file systems for temporary files, process information, etc. A computer can have multiple storage devices and file systems across different partitions and disk volumes.

Uploaded by

abdulbarimalik
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views16 pages

Directory and Disk Structure: Presented by

The document discusses directory and disk structure. It can be summarized as follows: 1. A directory structure is a collection of nodes containing information about all files and directories, organized in a tree structure. Disks can be divided into partitions which can contain file systems. 2. Disk partitions can be formatted with different file systems like UFS or ZFS. Each file system contains metadata about the files and directories in the device directory. 3. In addition to general file systems, there are special purpose file systems for temporary files, process information, etc. A computer can have multiple storage devices and file systems across different partitions and disk volumes.

Uploaded by

abdulbarimalik
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 16

Directory And Disk Structure

Presented By :
Abdul Bari Reg No : 905 FBAS/ DSE/ F-09

Directory Structure
A collection of nodes containing information about all files
Directory

Files

F1

F2

F3

F4 Fn

Both the directory structure and the files stored on Random access storage devices including hard disks , optical disks and solid state disks Backups of these two structures are kept on tapes

Disk Structure
Disk can be subdivided into partitions Disks or partitions can be RAID protected against failure Disk or partition can be used raw without a file system, or formatted with a file system Partitioning is useful for limiting the size of individual file system Partitions also known as minidisks, slices Entity containing file system known as a volume . Each volume containing file system also contain that file systems info in device directory or volume table of contents

Storage Structure
As well as general-purpose file systems there are many special-purpose file systems, frequently all within the same operating system or computer. We consider only general purpose file systems General Purpose computer systems has multiple storage devices and those devices can sliced up into volumes that holds file systems . Computer systems may have zero or multiple file systems , and the file systems may be of varying types . Consider the some file systems in Solaris . tmpfs (temporary file system) ctfs (virtual file system maintains contract info) procfs (presents info on all processes on file system ) ufs, zfs (general-purpose file system )

A Typical File-system Organization

Operations Performed on Directory


Search for a file Create a file Delete a file List a directory Rename a file Traverse the file system

Organize the Directory (Logically) to Obtain


Efficiency locating a file quickly Naming convenient to users Two users can have same name for different files The same file can have several different names Grouping logical grouping of files by properties, (e.g., all Java programs, all games, )

Single-Level Directory
A single directory for all users

Naming problem
Grouping problem

Two-Level Directory
Separate directory for each user

Path name Can have the same file name for different user Efficient searching No grouping capability No sharing capability

Tree-Structured Directories

Tree-Structured Directories (Cont)


Efficient searching

Grouping Capability
Current directory (working directory) cd /spell/mail/prog type list Absolute or relative path name Creating a new file is done in current directory Delete a file rm <file-name> Creating a new subdirectory is done in current directory mkdir <dir-name> Example: if in current directory /mail mkdir count

Acyclic-Graph Directories
Have shared subdirectories and files

Acyclic-Graph Directories (Cont.)


Two different names (aliasing) If dict deletes list dangling pointer Solutions: Backpointers, so we can delete all pointers Variable size records a problem Backpointers using a daisy chain organization Entry-hold-count solution New directory entry type Link another name (pointer) to an existing file Resolve the link follow pointer to locate the file

General Graph Directory

General Graph Directory (Cont.)


How do we guarantee no cycles? Allow only links to file not subdirectories Garbage collection Every time a new link is added use a cycle detection algorithm to determine whether it is OK

You might also like