& Data Processing 2. Exercise 2: File Systems. Dipl.-Ing. Bogdan Marin. Universität Duisburg-Essen



Similar documents
Prof. Dr. Ing. Axel Hunger Dipl.-Ing. Bogdan Marin. Operation Systems and Computer Networks Betriebssysteme und Computer Netzwerke

File System Management

Types Of Storage Device

McGraw-Hill Technology Education McGraw-Hill Technology Education

Main Memory & Backing Store. Main memory backing storage devices

Writing Assignment #2 due Today (5:00pm) - Post on your CSC101 webpage - Ask if you have questions! Lab #2 Today. Quiz #1 Tomorrow (Lectures 1-7)

CSCA0201 FUNDAMENTALS OF COMPUTING. Chapter 5 Storage Devices

University of Dublin Trinity College. Storage Hardware.

CHAPTER 17: File Management

TELE 301 Lecture 7: Linux/Unix file

Chapter 2: Computer-System Structures. Computer System Operation Storage Structure Storage Hierarchy Hardware Protection General System Architecture

CSCA0102 IT & Business Applications. Foundation in Business Information Technology School of Engineering & Computing Sciences FTMS College Global

Chapter 8. Secondary Storage. McGraw-Hill/Irwin. Copyright 2008 by The McGraw-Hill Companies, Inc. All rights reserved.

Today we will learn about:

File Systems Management and Examples

File System & Device Drive. Overview of Mass Storage Structure. Moving head Disk Mechanism. HDD Pictures 11/13/2014. CS341: Operating System

Two Parts. Filesystem Interface. Filesystem design. Interface the user sees. Implementing the interface

Incident Response and Computer Forensics

& Data Processing 2. Exercise 3: Memory Management. Dipl.-Ing. Bogdan Marin. Universität Duisburg-Essen

Topics in Computer System Performance and Reliability: Storage Systems!

Chapter 8 Memory Units

Storage in Database Systems. CMPSCI 445 Fall 2010

Physical Data Organization

William Stallings Computer Organization and Architecture 7 th Edition. Chapter 6 External Memory

COS 318: Operating Systems. File Layout and Directories. Topics. File System Components. Steps to Open A File

1 File Management. 1.1 Naming. COMP 242 Class Notes Section 6: File Management

Chapter 10: Mass-Storage Systems

Storing Data: Disks and Files. Disks and Files. Why Not Store Everything in Main Memory? Chapter 7

COS 318: Operating Systems

Operating Systems CSE 410, Spring File Management. Stephen Wagner Michigan State University

Discovering Computers Chapter 7 Storage

Disks and RAID. Profs. Bracy and Van Renesse. based on slides by Prof. Sirer

NCTE Advice Sheet Storage and Backup Advice Sheet 7

Algorithms and Methods for Distributed Storage Networks 7 File Systems Christian Schindelhauer

File-System Implementation

Chapter 3: Computer Hardware Components: CPU, Memory, and I/O

Chapter 12 File Management

Operating System Concepts. Operating System 資 訊 工 程 學 系 袁 賢 銘 老 師

Record Storage and Primary File Organization

Chapter 12: Secondary-Storage Structure

Primary Memory. Input Units CPU (Central Processing Unit)

Windows OS File Systems

Computers Are Your Future Prentice-Hall, Inc.

Mass Storage Structure

William Stallings Computer Organization and Architecture 8 th Edition. External Memory

With respect to the way of data access we can classify memories as:

6. Storage and File Structures

FAT32 vs. NTFS Jason Capriotti CS384, Section 1 Winter Dr. Barnicki January 28, 2000

Two main categories of storage technology used today are magnetic storage and optical storage.

Project Group High- performance Flexible File System 2010 / 2011

Data Storage - I: Memory Hierarchies & Disks

Unit Storage Structures 1. Storage Structures. Unit 4.3


How To Store Data On A Computer (For A Computer)

CPS104 Computer Organization and Programming Lecture 18: Input-Output. Robert Wagner

Sistemas Operativos: Input/Output Disks

Chapter 3 Storage. 15 th Edition Understanding Computers Today and Tomorrow Comprehensive. Deborah Morley Charles S. Parker

To understand how data is processed, by a computer, we can draw a simple analogy between computers and humans.

Chapter 12: Mass-Storage Systems

Introduction Disks RAID Tertiary storage. Mass Storage. CMSC 412, University of Maryland. Guest lecturer: David Hovemeyer.

Lecture 18: Reliable Storage

Lecture 1: Data Storage & Index

Storing Data: Disks and Files

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

Devices and Device Controllers

Outline. CS 245: Database System Principles. Notes 02: Hardware. Hardware DBMS Data Storage

CS 153 Design of Operating Systems Spring 2015

Machine Architecture and Number Systems. Major Computer Components. Schematic Diagram of a Computer. The CPU. The Bus. Main Memory.

Storage and File Systems. Chester Rebeiro IIT Madras

Introduction to I/O and Disk Management

Chapter 12 File Management

Chapter 12 File Management. Roadmap

Chapter 7 Types of Storage. Discovering Computers Your Interactive Guide to the Digital World

Here are my slides from lecture, along with my notes about each slide.

INTRODUCTION The collection of data that makes up a computerized database must be stored physically on some computer storage medium.

Secondary Storage. Any modern computer system will incorporate (at least) two levels of storage: magnetic disk/optical devices/tape systems

The Linux Virtual Filesystem

Filing Systems. Filing Systems

Computer Logic (2.2.3)

Platter. Track. Index Mark. Disk Storage. PHY 406F - Microprocessor Interfacing Techniques

Module 2: File Systems and Management

Backup Technologies. An Overview of the Different Technologies Available for Backup. What do I need to think about when choosing a backup solution

Copyright 2007 Ramez Elmasri and Shamkant B. Navathe. Slide 13-1

Backup and Restore User manual For version

Introduction To Computers: Hardware and Software

Outline. mass storage hash functions. logical key values nested tables. storing information between executions using DBM files

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

Lecture 16: Storage Devices

COMPUTER FORENSICS. DAVORY: : DATA RECOVERY

Holographic Memory. Darrell Draper Phillip Palmer

COSC 6374 Parallel Computation. Parallel I/O (I) I/O basics. Concept of a clusters

Main Points. File layout Directory layout

CS 6290 I/O and Storage. Milos Prvulovic

Tech Application Chapter 3 STUDY GUIDE

Examine Your Strategy, Weigh Your Options in Choosing Removable Storage. Dave Holmstrom Associate Director of New Products Verbatim Corporation

Computer Peripherals

USB Flash Drive User s Manual

Data Storage and Backup. Sanjay Goel School of Business University at Albany, SUNY

Windows NT File System. Outline. Hardware Basics. Ausgewählte Betriebssysteme Institut Betriebssysteme Fakultät Informatik

Transcription:

Folie a: Name & Data Processing 2 2: File Systems Dipl.-Ing. Bogdan Marin Fakultät für Ingenieurwissenschaften Abteilung Elektro-und Informationstechnik -Technische Informatik-

Objectives File System Concept File Management Mass Storage Physical Concept File Allocation Table & Unix File System Management of Free Blocks

File System Concepts What are Files Named collection of information stored on mass storage media Logical storage units Two aspects: User s view User Interface System Designer s view Implementation User Interface results in two distinct notions: Files: storing a collection of data Directory Structure: organising & providing info abt files in system

File Management Administration of mass storage media and the devices which control them Creation and deletion of files To map and find files onto the physical media File Access: WHO can and HOW to

Mass Storage Refers to various techniques and devices for storing large amounts of data Three essential requirements are: Able to store large amount of information Storage must be non-volatile or persistent Stored information can be accessed concurrently Mass Storage vs. Memory Memory is volatile

Mass Storage Media Magnetic tapes: tape streamer + : cheap, large storage capacity, backup purposes - : Disadv: slow, sequential access Magnetic disks type 1: harddisk + : fast, higher storage capacity - : more expensive, not necessay portable, bulky Magnetic disks type 2: floppy disks, zip + : portable disk, universal, cheap, direct access - : slow, small storage capacity Optical disks: CD, DVD + : very large storage capacity, portable disk, read-only disk/drives cheap - : slower than harddisk, write disk drives expensive

Physical Concept (1/3) Example : Inside the Hard Disk Hard-disk drive Controller electronic Connection & Vent hole Platters, Arms & Heads Multiple platters Multiple arms & heads High-speed linear motor

Physical Concept (2/3) One or more metal platters rotate at 5400, 7200 or 10 800 rpm A mechanical arm pivots over the platters from the corner At any given arm position, each of the heads can read/write a circular region called a track All the tracks for a given arm position form a cylinder Each track is divided into sectors (typically 512 bytes per sector)

Physical Concept (3/3) Storing the Data 0 Heads 0..NoH-1 1 NoH-2 NoH-1 Sectors 0... NoS-1 NoH : Number of heads to read/write NoT : Number of tracks NoS : Number of sectors per track NBS : Number of bytes per sector Tracks 0... NoT-1

Storage Capacity The storage capacity of a mass storage media (BV) BV = NoH * NoT * NoS * NBS NOTE : NBS is by default 512 bytes!

Storage Capacity Given a standard format 8-inch floppy disk with 2 heads, 80 tracks, 18 sectors per track, four 128- byte units per sector (512 B), what is ist storage capacity in kilobytes [KB] BV = 2 * 80 * 18 * (4*128) [B] BV = 2 * 80 * 18 * 512 [B] BV = 1474560 [B] BV = 1440 [KB]

File Allocation Table (FAT) FAT = a table that OS uses to locate files on the disk. FAT12 is the oldest type of FAT, which uses a 12-bit binary number to hold the cluster number. cluster number is not the same as the sector number (the system designer can define the number of physical sectors in a logical cluster on a disk). A cluster = group of sectors on the disk that have information in them. A 4K cluster has 8 physical sectors (NBS) in it (512*8=4096). Each Cluster has an entry in the FAT table.

File Allocation Table The FAT file system comes in three versions for MS DOS: FAT12, FAT16 and FAT32. Calculate the: Size of maximum disk partition for each of the FAT version in Table 1 Size of FAT12 Size of FAT16 Size of FAT32

File Allocation Table Cluster Size [KB] FAT12 FAT16 FAT32 0.5 1 2 4 8 16 32

Max Disk Partition (1) Given Cluster Size = 0.5 [KB] with FAT12 Max disk partition = 2 12 * 512 [B] = 2 [MB] Given Cluster Size = 2 [KB] with FAT16 Max disk partition = 2 16 * 2 [KB] = 128 [MB] Given Cluster Size = 4 [KB] with FAT32 Max disk partition = 2 28 * 4 [KB] = 2 10 * 2 10 * 2 8 * 2 2 [KB] = 1 [TB]

Max Disk Partition (2) Cluster FAT12 Size [KB] [MB] 0.5 0.5*2 12 =2 1 1* 2 12 =4 FAT16 [MB] FAT32 [TB] 2 2* 2 12 =8 128 4 2 2 *2 12 =16 2 2 *2 16 =256 1 8 2 3 *2 16 =512 2 16 2 4 *2 16 =1024 2 32 2 5 *2 16 =2048 2 Partitions are limited to 2 TB because internally, the system keeps track of the partition size in 512 Byte sectors using a 32 bit number: 512 Bytes * 2 32 = 2 TB

Unix File System A Typical Unix partition Directory entry i-node

Unix File System Assume disc blocks are 8K bytes and that disc addresses are 32 bits: What size can be directly addressed from the information in the i-node What size of file requires a double indirect block What is the largest possible file Answer: a) Disk blocks= 8K bytes i-node => 10 disk block adress 8K*10= 80K can be accessed directly

Unix File System b) Single indirect: (address of disk block which itself contains the disk block addresses) One 8K block can address : 2 3 *2 8 =2 11 = 2048 addresses of 8K blocks Can access file size: 2048*8k=16M Double indirect: (address of disk block with the addresses of single indirect blocks) 2048*2048= 4 194 304 (2 22 ) addresses of 8K blocks Can access file size: 4194304 *8k=32G c) Triple indirect: (address of disk block with the addresses of double indirect blocks) 2048*2 22 =2 33 addresses of 8K blocks Can access file size: 2 33 *8k=64TB Largest file: 64TB + 32G + 16M + 80K

Free Space Management How to keep track of free blocks Method 1: Linked List Linked lists of disk blocks, each block has as many free disk block no. as will fit in One slot needed for the pointer to the next block Method 2: Bitmap A disk with n blocks requires a bitmap with n bits Free blocks 1, used blocks 0 (or viceversa) Bitmap vs. Linked List 1 bit/block vs. 32bits/block

Free Space Management The beginning of a free space bitmap looks like this after the disk partition is first formatted: 1000 0000 0000 0000 (the first block is used by the root directory). The system always searches for free blocks starting at the lowest numbered block, so after writing file A, which uses 6 blocks the bitmap looks like this: 1111 1110 0000 0000. Show the bitmap after each of the following additional actions: File B is written using 5 blocks File A is deleted File C is written, using 8 blocks File B is deleted

Free Space Management 1000 0000 0000 0000 (begining) 1111 1110 0000 0000 (file A is written ) 1111 1111 1111 0000 (file B is written ) 1000 0001 1111 0000 (file A is deleted ) 1111 1111 1111 1100 (file C is written ) 1111 1110 0000 1100 (file B is deleted )

Next Week: Memory Management.. Check the webpage for exercises! http://www.fb9dv.uni-duisburg.de/ti/en/education/ss06/dv2/main.html