file systems Flashcards

(36 cards)

1
Q

main function of a file system

A

main permanent data storage

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

is capacity a problem nowadays?

A

no, 2TB even for PC

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

if capacity is not a problem what is

A

backup becoming a problem

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

logical view of file systems

A

tree structure of files
together with read/write operation and creation of directories

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

physical view of file system

A

sequence of blocks, which can be read and
written. OS has to map logical view to physical view, must impose tree structure and assign blocks for each file

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what are the 2 main possibilities to realise filesystems

A

linked lists
index allocation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

describe linked list in file systems

A

Each block contains pointer to next
⇒ Problem: random access (seek()) costly: have to go
through whole file until desired position

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

describe index allocation in file systems

A

Store pointers in one location: so-called
index block (similar to page table). To cope with vastly
differing file sizes, may introduce indirect index blocks

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

what are index blocks in unix

A

inodes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

what do is something additional inodes do

A

they store additional info about the file
eg size,
permissions)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

what does FAT stand for

A

File Allocation Table

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

describe FAT

A

F(ile) A(llocation) T(able) – dates back to 70s.
Useful for explaining filesystem concepts, modern filesystems
are more complicated
Variants FAT12. FAT16, FAT32 define number of bits per
FAT entry – we focus on FAT16
Sector = disk unit (e.g. 512 byte), aka block
Cluster = multiple sectors (factor 1, 2, 4, . . . , 128)
(here: assume cluster = 1 sector)
Uses linked list (“cluster chain”) to group clusters

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

what does sector mean in FAT

A

Sector = disk unit (e.g. 512 byte), aka block

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

what does Cluster mean In FAT

A

Cluster = multiple sectors (factor 1, 2, 4, . . . , 128)
(here: assume cluster = 1 sector)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

what is use to grop clusters in FAT

A

linked lists

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

what is the max volume size of FAT16

A

2 GB (216 · 32 kB)

17
Q

what is the max file size of FAT16

18
Q

what is the max number of files of FAT16

A

65,460 (32kb clusters)

19
Q

how do new filesystems overcome FAT limits

A

overcome these limits,
using other data structures (e.g. B-tree for dir structure,
bitmap for allocation)

20
Q

describe cachine

A

Disk blocks used for storing directories or recently used files cached in main memory
Blocks periodically written to disk
⇒ Big effiency gain
Inconsistency arises when system crashes
Reason why computers must be shutdown properly

21
Q

describe journaling file systems

A

Define Transaction points: Points where cache is written to disk
⇒ Have consistent state
Keep log-file for each write-operation
Log enough information to unravel any changes done after latest transaction point

22
Q

disk access contains 3 parts
what are they?

A

Seek
latency
transfer

23
Q

what is seek in data access

A

head moves to appropriate track

24
Q

what is latency in disk access

A

correct block is underhead

25
what is transfer in disk access
data transfer
26
describe disk access time in HDDS
HDDs: Time necessary for seek and latency dwarfs transfer time ⇒ Distribution of data and scheduling algorithms have vital impact on performance for HDDs, less so for SSDs
27
name 2 disk acheduling algorithms
FCFS Shortest seek time first SCAN scheduling
28
describe FCFS in disk scheduling
easiest to implement, but: may require lots of head movements
29
describe shortest seek time first in disk scheduling
select job with minimal head movement
30
problems with shortest seek time first
may cause starvation tracks in the middle of disks preferred.
31
Describe scan scheduling in disk scheduling
Head continuously scans the disk from en to end (lift strategy) ⇒ solves the fairness and starvation problem of SSTF
32
improvement to scan scheduling
look scheduling
33
what does look scheduing do?
head only moved as far as last request (lift strategy)
34
describe disk algorithm used for swap space management
Particular tasks may require different disk access algorithms Example : Swap space management Speed absolutely crucial ⇒ different treatment: Swap space stored on separate partition Indirect access methods not used Special algorithms used for access of blocks Optimised for speed at the cost of space (eg increased internal fragmentation
35
describe linux implementation
Interoperability with Windows and Mac requires support of different file systems (eg vfat) ⇒ Linux implements common interface for all filesystems Common interface called virtual file system virtual file system maintains inodes for files and directories caches, in particular for directories superblocks for file systems All system calls (eg open, read, write and close) first go to virtual file system If necessary, virtual file system selects appropriate operation from real file system
36
describe kernel disk scheduler
File systems Disk Scheduler Kernel makes it possible to have different schedulers for different file systems Default scheduler (Completely Fair Queuing) based on lift strategy have in addition separate queue for disk requests for each process queues served in Round-Robin fashion Have in addition No-op scheduler: implements FIFO Suitable for SSD’s where access time for all sectors is equal