Operating Systems Flashcards

1
Q

Two Objectives of Operating System

A

Convenience and Efficiency

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

What is an Operating System

A

Program that controls the execution of application programs and acts an interface between applications and the computer hardware

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

How does an operating system conceal complexity?

A

Protect users and programmers from having to work with horrendous complexity

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

How do the OS and hardware work together?

A
  • Protects the programmer and user from the details of the hardware
  • Provides a user interface
  • Works better if the hardware provides support for the OS
  • Developed together
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How does the OS do memory management?

A
  • Allocate memory to programs
  • Manage Virtual Memory
  • Protect against programming errors & malware
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How does the OS do Task management?

A
  • Launch processes
  • Maintain process table: list of running processes
  • Carry out timeslicing and context switching
  • Handle interrupts
  • Set program privilege levels
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How does the OS do File management?

A
  • Respond to program requests to open, read, write and close files
  • Set and check permissions
  • Handle buffering
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

How does the OS do Device management?

A

Use device drivers to respond to requests to open, read, write and close devices

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

Essential hardware features for an OS

A
  • Memory protection
  • Timer
  • Privileged instructions
  • Interrupts
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is a process?

A

Running a program

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

What does a process include?

A
  • Code
  • Data
  • Resources
  • Current state: registers
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is context switching?

A

The state of a running process is saved, and another process is given processor resources

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

What is a process control block?

A

A data structure used by a computer operating system to store all the information about a process

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

What are the different types of scheduling?

A
  • Long-term scheduling
  • Medium-term scheduling
  • Short-term scheduling
  • I/O scheduling
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is long-term scheduling?

A

The decision to add to the pool of processes to be executed

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

What is medium-term scheduling?

A

The decision to add to the number of processes that are partially or fully in main memory

16
Q

What is short-term scheduling?

A

The decision as to which available process will be executed by the processor

17
Q

What is I/O scheduling?

A

The decision as to which process’s pending I/O request shall be handled by an available I/O device

18
Q

What is swapping?

A

The operating system stores a queue of processes wanting to execute (Processes on the disk, queue in the kernel). As space becomes available, the processes are loaded and when a process finishes it is removed. Stalled processes are swapped out e.g. waiting for I/O

19
Q

What is partitioning?

A

A memory management technique that divides a computer’s memory into sections for use by programs

20
Q

What is the difference between fixed size and variable size partitions?

A

Fixed size
- Logarithmic distribution of partition sizes
- Easy to administer
Variable size
- Memory is allocated as required
- Fragmentation makes it harder to load incoming processes

21
Q

What is a logical address?

A

An address seen by the process and is relative to the programs address space.

22
Q

What is a physical address?

A

An actual location in memory

23
Q

What is a base address?

A

The current starting location of the process

24
Q

What is paging?

A
  • Divides the physical memory into small, equal chunks (frames)
  • Divides the processes into chunks (pages) of the same size as the memory frames
25
Q

What is virtual memory?

A

Allows processes larger than physical memory to be loaded

26
Q

What is demand paging?

A

Each page of a process is brought when it is needed

27
Q

What are the advantages of demand paging?

A
  • More processes can be maintained in memory
  • Time is saved because unused pages are not swapped in and out of memory
28
Q

What are disadvantages of Demand paging?

A
  • When one page is brought in, another must be thrown out
  • If the thrown out page was about to be used OS needs to go get it again
  • Thrashing
29
Q

What is segmentation?

A
  • Segmentation allows the programmer to view memory as consisting of multiple address spaces or segments
  • Segments are of variable size
30
Q

What are the advantages of segmentation?

A
  • Simplifies the handling of growing data structures
  • It allows programs to be altered ad recompiled independently without requiring that an entire set of programs be relinked and reloaded
  • It lends itself to sharing among processes
  • It lends itself to protection
31
Q

Where is Virtual Software placed?

A

Between hardware and conventional software

32
Q

What is a Virtual Machine Monitor?

A

A layer of software emulating hardware of a complete computer system that provides an abstraction called VM. VMM provides the illusion of multiple machines on a single physical machine

33
Q

What does Binary translation do for VM?

A

Translates the code to the new code needed for the VM, detecting all the sensitive privileged instructions

34
Q

What is paravirtualisation?

A

Changes the guest OS so it cooperates with the VMM, the VMM exposes hypercalls and uses events to trigger interrupts