Search
Course outline
  1. 01How a computer works
    1. 1.1What is a computer?(completed)
    2. 1.2The CPU: the brain(completed)
    3. 1.3Memory: RAM vs storage(completed)
    4. 1.4How the CPU and memory work together(completed)
    5. 1.5What happens when you turn on a computer(completed)
  2. 02How the Internet works
    1. 2.1What is the Internet?(completed)
    2. 2.2Addresses and names: IP and DNS(completed)
    3. 2.3Packets: how information travels(completed)
    4. 2.4Client and server: opening a website(completed)
    5. 2.5Inside a busy server(completed)
    6. 2.6Why this matters for AI(completed)
  3. 03Introducing the GPU
    1. 3.1What is a GPU?(completed)
    2. 3.2CPU vs GPU(completed)
    3. 3.3The GPU's own memory: VRAM(completed)
    4. 3.4How the CPU and GPU work together(completed)
    5. 3.5Why GPUs suit AI(completed)
  4. 04Tensors and models
    1. 4.1What is a tensor?soon
    2. 4.2What is an AI model?soon
    3. 4.3Training vs inferencesoon
  5. 05Splitting work across GPUs
    1. 5.1Why split work across GPUs?soon
    2. 5.2Data parallelismsoon
    3. 5.3Tensor parallelismsoon
    4. 5.4Pipeline parallelismsoon
    5. 5.5Expert parallelismsoon
    6. 5.6Which to use whensoon
  6. 06Serving LLMs with vLLM
    1. 6.1What is LLM serving?soon
    2. 6.2Meet vLLMsoon
    3. 6.3Serving a model with vLLMsoon

Lesson 1.5

What happens when you turn on a computer

From pressing the power button to a screen that is ready to use.

beginner 4 min readChecked

In one line

When you press the power button, built-in firmware wakes up, checks the hardware, starts a small bootloader, and the bootloader loads the operating system into RAM.

Real-life analogy

Think about opening the restaurant in the morning.

  1. You unlock the door and switch on the power.
  2. The lights and basic systems come on by themselves.
  3. Someone does a quick walk around the kitchen: is the oven working? Is the fridge cold?
  4. You follow the opening checklist taped by the door.
  5. The manager arrives and sets up the counter for the day.
  6. The sign flips to Open.

Starting a computer, called booting, follows the same kind of order.

Where the comparison stops working: opening a restaurant takes an hour of human judgement. Booting is fully automatic and usually takes seconds. And unlike a restaurant, the counter (RAM) is completely empty every morning, because it forgot everything when the power went off.

Diagram

1. Power on2. Firmware starts(UEFI or BIOS)3. Hardware check(POST)4. Find and startthe bootloader5. Operating systemloads into RAM6. Ready to useRestaurant: unlock the door, switch on the lights, check the kitchen,read the opening checklist, set up the counter, open for customers.
Booting: power, firmware, hardware check, bootloader, operating system into RAM, ready.

Step by step

Here is a puzzle. In lesson 1.3 we learned that RAM forgets everything when the power is off. And in lesson 1.4 we learned that the CPU runs instructions from RAM.

So when you switch on a computer, RAM is empty. Where does the CPU get its very first instruction? Let’s find out.

Step 1: power on

You press the power button. Electricity flows to the main board, the CPU, the RAM, the storage and the fans.

Step 2: firmware starts

The answer to our puzzle: every computer has a small program called firmware, stored on a chip on the main board. Unlike RAM, that chip keeps its contents without power.

The CPU is built to start by running this firmware. On most modern PCs it is called UEFI. Older PCs used BIOS, and many people still say “BIOS” for both.

Step 3: hardware check

The firmware runs a quick check of the hardware, often called POST (power-on self-test). It makes sure the essential parts are present and working, and gets them ready to use.

If something important is missing or broken, the computer may stop here, sometimes with beeps or an error message.

Step 4: find and start the bootloader

Next, the firmware looks in storage for a small program called the bootloader. Its only job is to start the operating system.

On Windows, this is the Windows Boot Manager. On Linux, a common one is GRUB.

Step 5: the operating system loads into RAM

The bootloader finds the core of the operating system, called the kernel, in storage and copies it into RAM. Then it hands over control.

The kernel sets up the rest of the system: it starts the drivers (small programs that know how to talk to each piece of hardware), and then starts the background services.

Step 6: ready to use

Finally you see the login screen or home screen. The manager is in, the counter is set up, and the restaurant is open. From here, everything works the way we saw in lesson 1.4.

Key takeaways

  • At power-on, RAM is empty, so the first instructions come from firmware (UEFI or BIOS) on a chip that remembers.
  • The firmware checks the hardware (POST), then starts the bootloader.
  • The bootloader loads the operating system’s kernel into RAM and hands over control.
  • The operating system starts drivers and services, and then the computer is ready to use.

Recap: unlock, lights on, check the kitchen, follow the checklist, set up the counter, open. Power, firmware, hardware check, bootloader, operating system, ready.

Now you understand what happens between pressing the power button and seeing your screen. That completes Module 1: you now know how a computer works inside. Next, we will connect computers together and look at how the Internet works.

Quick check

Pick an answer, then press Check answer. Nothing is recorded.

  1. Right after you press the power button, why can't the CPU just start the operating system?
  2. What is the job of the bootloader?
  3. Put these in order: A) bootloader, B) hardware check, C) operating system loads into RAM.

Sources

This lesson was checked against these pages.

  1. Windows startup issues troubleshooting (phases of the startup process) · Microsoft Learn
  2. Secure the Windows boot process · Microsoft Learn
  3. What Is Computer and Laptop RAM and Why Does It Matter? · Intel