Questions
An Introduction to Operating Systems
- Why were operating systems developed initially?
- How did the features of operating systems evolve along with the development of the available hardware?
- How do we define the term "operating system" today?
- What are the building blocks of a computer system?
- CPU, RAM, character and block I/O device, bus
- Which resources are represented by these building blocks?
- Disk is a block device
- Terminal and printer are character devices
- How does code (in the OS) interact with hardware resources?
- Device handling, device drivers
- Port and memory mapped I/O
- Interrupts (async notification)
- DMA
- What are the most relevant developments in computer architecture of the last decades and which problems/benefits are related to these developments?
Challenges and Tasks of Operating Systems
- Which abstractions does a modern OS provide?
- CPUs, processes, memory, file systems, security, ...
- What is a process?
- How do processes interact with each other and the OS?
- System calls
- Synchronization and deadlock fundamentals
- What different view of processes exists and why?
- Which states can a process have and what characterizes the different states?
- What transitions between states are legal?
Processes and Threads
- What is the definition of a process and what is the difference to a program?
- What is a process hierarchy and why does it exist?
- Parent/child processes, orphans, zombies and PID 1 (init)
- How can processes perform I/O, how can it be (re)configured?
- Relation of the I/O concept to the Unix philosophy?
- Do one thing, and do it well
- Everything is a file
- How do processes interact with the OS: system calls
- How can processes be created/controlled/terminated?
- Which Unix syscalls are used for process management?
- Pros and cons of the Unix fork/exec model
- Optimizations for process creation in Unix: copy-on-write
- What are details of the extended process state model?
- What is the overhead of Unix processes and their creation?
- What are the differences between address spaces for processes and threads?
- What are the thread models in Unix and Windows?
- What are fibers (user-level threads)?
- Can you discuss pros and cons of threads vs. fibers?
- Cooperative multithreading
- Can you describe the ideas behind Duffβs device and protothreads? (you donβt have to know the details of their implementations)
- Difference between the cooperative and preemptive ways
Concurrency: Mutual exclusion, Synchronisation, Deadlocks
- What is shared data/memory communication, why is it problematic?
- Can you give an example of a problematic situation?
- Can you understand multithreaded code using shared data?
- What is a race condition (can you give examples)?
- Why are race conditions hard to detect and debug?
- What is synchronization used for, which options for synchronization exist?
- Can you define the term "critical section"?
- What are locks and how are they used?
- Can you give details on lock implementations (atomic operations, suppressing interrupts, semaphores)?
- What is a semaphore, which operations exists on semaphores?
- Can you define the use and implementation of semaphores?
- Can you describe problems (e.g. reader/writer) solved using semaphores?
- What are monitors and how to they differ from semaphore solutions?
- Can you define the terms "deadlock" and "livelock"?
- Explain situations leading to both problems
- What are the necessary conditions for deadlocks to occur?
- What is the additional condition that is required for a deadlock to occur?
- Which types of resources exists related to synchronization?
- What are the components of a resource allocation graph, how do you construct it?
- How can you detect a deadlock in this graph?
- Why is this not effective in practise?
- What is the dining philosophers problem?
- Why do deadlocks occur here?
- Can you describe a solution to solve the problem?
- Can you discuss the efficiency of different solutions?
- How can deadlocks be prevented and what are safe/unsafe states?
- Which methods exist to resolve a deadlock and what are their pros/cons?
Memory management and Virtual Memory
- Requirements for memory management for multiprogramming systems?
- Which policies and strategies are relevant for memory management?
- Can you describe the basic problem of memory allocation?
- How does dynamic memory allocation work?
- Can you describe different approaches, describe pros/cons?
- Can you name and describe different placement strategies?
- What is memory fragmentation?
- Which kinds of fragmentation exist, what are their properties?
- Internal and external fragmentation
- Where are different allocation methods typically used?
- Can you describe differences between swapping, segmentation, paging?
- How does paging as an OS concept interact with the MMU (and TLB, and page tables)?
- How can paging be optimized using hardware or software approaches (like TLB)?
- What is the locality principle in computers?
- Which kinds of locality exist, can you describe their properties?
- How can locality be used to optimize performance?
- What is the idea behind virtual memory, which abstraction/illusion is created by virtual memory?
- How does demand paging work?
- What is a page fault and how is it handled?
- What are tasks of the OS and hardware when handling page faults?
- Can you name different page replacement strategies and discuss their pros/cons? (FIFO, optimal, LRU, second chance)
- Can you simulate different strategies given an access sequence?
- Can you define thrashing and name causes and possible solutions?
- What is the working set of a process and how can you determine it?
Scheduling: Uni- and Multiprocessor
- Which approaches to inter-process communication (IPC) exist?
- Can you give their pros/cons?
- What are the primitives for message-based communication?
- Which synchronization methods exist here?
- How can processes be addressed?
- Which message formats exist?
- Which IPC methods exist in Unix?
- Can you describe the concepts and use (programming) ofβ¦
- Signals, unnamed pipes, named pipes, Unix message queues, sockets
- What is RPC and what is the fundamental difference to IPC?
- Can you define the terms "dispatching" and "scheduling"?
- Which dispatch states exist, which level of scheduling are they related to?
- Can you describe details of short/medium/long term scheduling?
- Which process state transitions are related to which scheduling level?
- Can you explain preemptive scheduling and its advantages?
- Can you give examples for scheduling strategies, explain how they work?
- Can you determine scheduling orders for a given strategy?
- Can you discuss pros/cons of the different scheduling strategies?
- What is multi-level scheduling and how is this related to priorities?
- Can you give details of scheduling strategies in Unix and Windows?
I/O Management and Disk Scheduling
- How do devices and the OS interact? Can you name different methods?
- Which classes of devices exist and what are their properties?
- Character devices, block devices etc.
- How do interrupts and DMA work and what are their pros/cons?
- How can I/O devices be addressed by the OS?
- What is a device driver, in which ways can it interact with the hardware?
- What are the various tasks of the OS related to devices?
- How are devices represented and abstracted in Unix?
- Name properties of/differences between character/block/other devices
- How does the OS implement the relation device special file <=> device driver?
- How can devices be used in user processes, what are related syscalls/libc functions?
- Why is buffering important, can you discuss the pros/cons?
- How does a ring buffer work, where is it typically used?
- How does I/O scheduling for disk drives work
- What are the pros/cons of the different scheduling approaches?
File Management
- What is the file abstraction and why is it useful?
- What are the syscalls/libc functions in Unix to handle files?
- What is a virtual file system and how does this work?
- What is mounting/unmounting, what is their effect on the directory tree of a Unix system?
- Which methods exist to map a file to disk blocks?
- Describe problems of the approaches/pros/cons
- Which methods exist to manage free space?
- What are the directory and inode structures for typical file systems?
- Unix System V, BSD FFS, Linux ext2/3/4
- What are the challenges for file systems today?
- How can the reliability of disk storage be improved?
- How can the performance of disk storage be improved?
- What is the Unix block buffer cache and how does it work?
- What is logical volume management and why is it useful?
- What is RAID?
- Which different RAID levels exist and how do they work?
- Can you discuss the pros/cons of the different levels?
- What is a journaling/log structured file system?
- How do they work, what are differences to traditional FS?
Virtual Machines and Microkernels
- Can you define monolithic kernels, microkernels, hypervisors?
- Differences between these, pros/cons?
- What problem did first-generation microkernels have?
- How was this solved in second-generation microkernels?
- What is an exokernel?
- What is virtualization, can you define its functionality?
- What is a virtual machine monitor or hypervisor?
- What are the differences between type 1 and 2 hypervisors?
- Which hardware support was introduced to support virtualization?
- What is paravirtualization and what are its pros/cons?
- What is a hypercall?
The Cloud, Unikernels and Single-Address Space OS's
- Which service models exist for Cloud systems?
- What are their properties, pros and cons?
- Which provisioning models exist?
- What does the architecture for a Cloud OS look like?
- What are differences to a "regular" OS?
- Which strategic decisions have to be taken by a Cloud OS?
- What is a container and how are containers related to virtualization?
- What is virtualized in containers?
- How does virtual memory management interact with virtualization for the Cloud?
- Which optimization approaches exist, can you describe them?
- How can I/O be virtualized for the Cloud?
- Which I/O virtualization approaches exist, can you name pros/cons?
Operating System Security
- Can you define safety and security?
- What is the task of OS security?
- Can you give examples for malware?
- What is the difference to social engineering?
- Which types of malware exist, can you define them?
- What is permission management and what are the related requirements?
- What is the principle of least privilege?
- Define the access matrix and describe the ways to use it
- File/process attributes in Unix
- ACLs, capabilities, mandatory access control
- How do the MMU and the CPU privilege levels contribute to security?
- What is software-based protection, can you give an example?
- Which typical software bugs contribute to security problems, can you give examples?