Final Exam Flashcards

(17 cards)

1
Q

What are the main CPU scheduling algorithms?

A

FCFS, SJF, SRTF, Priority, Round Robin, Multilevel Queue

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

What is the difference between preemptive and non-preemptive scheduling?

A

Preemptive can interrupt a running process, non-preemptive cannot

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

What is context switching?

A

The process of storing and restoring the state (context) of a CPU so that multiple processes can share a single CPU

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

What are the four necessary conditions for a deadlock?

A

Mutual exclusion, hold and wait, no preemption, circular wait

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

Name strategies for handling deadlocks.

A

Prevention, avoidance, detection and recovery

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

What is a safe state in deadlock avoidance?

A

A state where the system can allocate resources in some order and still avoid deadlock

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

What is paging?

A

Dividing memory into fixed-size pages to manage memory efficiently

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

What is the difference between internal and external fragmentation?

A

Internal: wasted space within allocated memory. External: small holes between allocated memory blocks

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

What is a page table?

A

A data structure used to map virtual addresses to physical addresses

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

What is demand paging?

A

Loading pages into memory only when they are needed

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

What is the difference between a page fault and a segmentation fault?

A

Page fault: valid page not in memory; segmentation fault: accessing invalid memory

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

Name common page replacement algorithms.

A

FIFO, LRU, Optimal, Clock

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

Which page replacement algorithm has the lowest page fault rate?

A

Optimal (but it requires future knowledge)

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

What are the main components of a file system?

A

Files, directories, file control blocks (FCB), inodes

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

What is the difference between contiguous and linked allocation?

A

Contiguous: blocks are stored together; Linked: blocks contain a pointer to the next block

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

What is the goal of a distributed system?

A

To make a network of computers appear as a single coherent system

17
Q

What is RPC (Remote Procedure Call)?

A

A protocol that allows a program to execute a procedure on another address space