Lecture 00: Prerequisites and Overview

Prerequisite Guide: Undergraduate Operating Systems Concepts and Laboratory

This document outlines the foundational knowledge and practical skills required for the undergraduate Operating Systems course.

Operating Systems is often the first course where students transition from writing high-level application code to interacting directly with system resources. The laboratory assignments will be conducted in a Linux environment and will require you to write programs in C that manage processes, memory, and file systems.

To succeed in this course, students must possess a strong grasp of basic procedural programming, data structures, and command-line navigation before the semester begins.


1. Conceptual Prerequisites

You must be comfortable with low-level memory concepts and foundational computer architecture.

1.1 The C Programming Language

The course labs rely heavily on C. Unlike Java or Python, C does not have garbage collection or built-in bounds checking.

To-Do / Self-Assessment: Write a C program that dynamically allocates an array of n integers (where n is provided by the user). Populate the array with random numbers, write a function to sort them in place, print the result, and correctly free the allocated memory.

1.2 Data Structures

Operating systems heavily utilize foundational data structures to manage queues of processes and memory blocks.

To-Do / Self-Assessment: Implement a doubly linked list in C. Write functions to insert_head, remove_tail, and print_list. Ensure your code handles edge cases, such as removing an item from an empty list.

1.3 Computer Organization Basics

You should understand the basic operation of a computer at the hardware level.


2. Laboratory Tooling & Environment

The laboratory component requires proficiency in a POSIX-compliant environment (Linux). Graphical User Interfaces (GUIs) will not be used for assignments.

2.1 Linux Command Line Interface (CLI) Basics

You must be able to navigate the file system and manipulate files using the terminal.

2.2 Compilation and Build Tools

2.3 Debugging and Profiling

Segmentation faults are the most common error in this course. You must know how to trace them.

To-Do / Self-Assessment: Introduce a deliberate memory leak in your linked list code from Section 1.2 (e.g., remove a node without calling free). Compile the code with the -g flag and run it through Valgrind. Observe the output report and fix the leak.

2.4 Note for Windows Users

The lab environment is exclusively Linux. If you are using a Windows machine for personal study, you should familiarize yourself with the following tools to interface with Linux environments:


The following texts bridge the gap between basic programming and systems-level understanding.

  1. Operating Systems: Three Easy Pieces (OSTEP) by Remzi H. Arpaci-Dusseau and Andrea C. Arpaci-Dusseau.
    • Note: This will likely be the primary textbook for the course. It is highly readable and available for free online. Focus on the early chapters covering Virtualization (Processes and Memory).
  2. Computer Systems: A Programmer’s Perspective (CS:APP) by Randal E. Bryant and David R. O’Hallaron.
    • Note: Excellent for understanding the transition from C code to machine execution. Chapters on system-level I/O and virtual memory are highly relevant.
  3. The C Programming Language (2nd Edition) by Brian W. Kernighan and Dennis M. Ritchie.
    • Note: The definitive guide for C syntax and standard library functions. Keep it as a reference for lab assignments.