COMP 3150Operating Systems

Module 1 · Unit 1 of 2

Introduction to Operating Systems

What an operating system is, why it exists, how it evolved from batch monitors to distributed and cloud systems, what services it provides, and how its major architectural forms differ. The unit opens with a hands-on orientation lesson that sets up the Linux virtual machine used throughout the course.

6 lessons · including orientation CLO1 — OS concepts & architectures ≈ 1.5 weeks at recommended pace
The operating system as resource manager and extended machine Applications sit above a set of operating-system abstractions — process, file, address space, socket — which hide the underlying CPU, memory, disk, and network hardware. A sidebar shows the initial orientation step: setting up the course Linux VM. APPLICATIONS editor compiler browser server OPERATING SYSTEM · ABSTRACTIONS process file address space socket resource manager · extended machine · protection boundary PHYSICAL HARDWARE CPU Memory Disk NIC START HERE · LESSON 1.0 SETS UP THE COURSE VM

00 Before you begin

Start with Lesson 1.0

Every laboratory, programming assignment, and exercise in this course runs on a Linux virtual machine. Before you begin the conceptual material of Lesson 1.1, complete Lesson 1.0 — Setting Up Your Course VM. It walks you through installing Ubuntu in a virtual machine, configuring the development toolchain, verifying the setup, and taking a baseline snapshot. The rest of the course assumes you have completed it.

01 Unit learning outcomes

Upon completion of this unit you will be able to

  • U1.1 — Explain the purpose and functions of operating systems.
  • U1.2 — Describe the historical evolution of operating systems.
  • U1.3 — Analyse operating-system services and system-call mechanisms.
  • U1.4 — Compare major operating-system architectures.
  • U1.5 — Evaluate architectural design trade-offs.

This unit addresses course learning outcome CLO1 — explain operating-system concepts, services, and architectures. The preliminary orientation lesson (1.0) prepares the ground for CLO6 — apply Linux systems-programming techniques and operating-system tools.

02 Lessons in this unit

Lesson 1.0 is a hands-on setup session that produces a working Linux virtual machine. Lessons 1.1 through 1.5 are the conceptual core of the unit and follow the standard eleven-part lesson structure — introduction, objectives, reading, content, worked examples, activity, knowledge check, discussion, practice, summary, and references.

03 What you will learn, lesson by lesson

1.0 Setting Up Your Course VM

  • Choose a virtualization platform.
  • Download and verify a Linux image.
  • Create and configure a VM.
  • Install and verify the toolchain.
  • Take a baseline snapshot.

1.1 What Is an Operating System?

  • Define an operating system.
  • Describe the OS as resource manager.
  • Describe the OS as extended machine.
  • Explain key OS functions.
  • Explain why operating systems are essential.

1.2 Evolution of Operating Systems

  • Describe major stages in OS evolution.
  • Compare batch and time-sharing systems.
  • Explain technological drivers.
  • Analyse the move to distributed and cloud systems.
  • Identify future trends.

1.3 Operating-System Services

  • Identify major OS services.
  • Explain program-execution services.
  • Explain I/O and file services.
  • Describe protection and security services.
  • Analyse service support for applications.

1.4 System Calls

  • Explain system calls.
  • Distinguish APIs from system calls.
  • Explain user mode and kernel mode.
  • Explain traps and interrupts.
  • Use Linux tools to observe system calls.

1.5 Operating-System Structures

  • Compare monolithic kernels.
  • Compare microkernels.
  • Compare hybrid kernels.
  • Analyse architectural trade-offs.
  • Evaluate OS designs.

04 Worked example

A taste of what the lessons will ask you to do. This example combines the setup work of Lesson 1.0 with the concepts from Lesson 1.4 (system calls) — the compile workflow that every laboratory in the course will use.

Task · build and inspect a small program in your VM

  1. Complete the VM setup. Work through Lesson 1.0 if you have not already. Your VM should be running Ubuntu with the toolchain installed, and you should have a baseline snapshot named clean-install.
  2. Open a terminal and create a working directory.
    mkdir -p ~/comp3150/exercises/unit1
    cd ~/comp3150/exercises/unit1
  3. Write a small C program.
    cat > hello.c << 'EOF'
    #include <stdio.h>
    #include <unistd.h>
    
    int main(void) {
        printf("hello from pid %d\n", getpid());
        return 0;
    }
    EOF
    Note that getpid is a system call — the program asks the kernel for its own process ID.
  4. Compile with the course-standard flags.
    gcc -Wall -Wextra -g -o hello hello.c
    -Wall enables warnings, -Wextra enables more, and -g includes debug symbols for GDB.
  5. Run the program.
    ./hello
    It prints its PID. That number was obtained by asking the kernel through a system call.
  6. Observe the system calls.
    strace -e trace=write,getpid,exit_group ./hello
    The trace shows every system call the program makes — a direct view of the interface between user space and kernel space, which Lesson 1.4 examines in detail.

What this example shows

The setup work of Lesson 1.0 and the conceptual material of the rest of the unit are not separate topics — they form a single workflow. Every laboratory in this course begins from exactly this pattern: a small program, compiled with standard flags, run under observation.

05 Required reading

Reading assignments are listed in each lesson. As a preview:

  • Lesson 1.0 — no textbook reading; consult the documentation for your virtualization platform and the Ubuntu installation guide.
  • OSTEP — Chapter 1, A Dialogue on the Book, and Chapter 2, Introduction to Operating Systems. Assigned in Lesson 1.1.
  • Operating System Concepts — Chapter 1 (introduction, services, system calls, and structures). Assigned across Lessons 1.2–1.5.

Read the manual for your VM platform

Every virtualization platform has documentation for installing and configuring a virtual machine. Skim the "creating a VM" and "installing a guest OS" sections before you start Lesson 1.0 — the walkthrough in that lesson assumes a basic familiarity with the concepts.

06 Unit discussion

Discussion prompt

Modern operating systems are often described as both a resource manager and an extended machine. Choose a system you use daily — a laptop, a phone, a cloud instance, or the VM you just set up — and identify one concrete decision its operating system makes that clearly serves each of those two roles. In at least one case, explain a trade-off where serving one role makes the other harder.

Post your response to the Unit 1 discussion forum and reply to at least two classmates. This activity contributes to your participation grade and supports CLO1.

07 Laboratory connection

The setup performed in Lesson 1.0 is what makes Lab 1 — Linux Fundamentals possible. Lab 1 is completed at the end of Unit 2, and it assumes the VM, toolchain, and workspace are all in place.

Where the setup work is used
Setup step Used in
Linux VM runningEvery laboratory in the course
Toolchain installedEvery programming exercise, from Lab 2 onward
Baseline snapshotRecovery point for any lab that goes wrong
Workspace repositoryVersion control for all labs and assignments

Do not skip Lesson 1.0

Students sometimes try to proceed directly to Lesson 1.1 without setting up the VM, planning to do it later. The conceptual material of Lessons 1.1–1.5 uses commands that run inside the VM, and the interactive activities assume a working environment. Setting it up first is faster overall than trying to catch up later.

08 Knowledge check & quiz

Quick check before you begin

Question 1

In one sentence, distinguish the operating system's role as a resource manager from its role as an extended machine.

Show a model answer
As a resource manager, the OS arbitrates access to CPU time, memory, storage, and devices among competing processes; as an extended machine, it presents a convenient, abstract view of the hardware that hides low-level detail and makes programs portable and easier to write.

Question 2

Why does the course use a virtual machine rather than installing Linux directly on your computer?

Show answer
For four reasons: isolation — the VM cannot damage your host system; reproducibility — every student runs the same environment; safety net — snapshots let you revert to a known-good state after mistakes; and portability — the VM is a set of files you can copy, back up, and transfer. Lesson 1.0 covers this in detail.

After completing all six lessons, take the Unit 1 quiz in the LMS. It covers the purpose, evolution, services, system calls, and structures of operating systems.

👤