Step-by-Step Guide to Installing Debian

Photo by Lukas on Unsplash

Step-by-Step Guide to Installing Debian

Installing Debian, a widely-used Linux distribution, can be installed easily with the right guide. This tutorial will take you through each step, from preparing your system to setting up Debian. Whether you're creating a server, a development environment, or just exploring Linux, this guide will help you install Debian smoothly. Let's get started!

Prerequisites

  • A USB with at least 4GB size.

  • A system with an internet connection (to download the ISO)

  • A system where you will install Debian. Minimal specifications:

    • A Pentium 4 1GHz processor or better.

    • 512 MB RAM (without a GUI desktop) or 2 GB (with GUI).

    • 2 GB hard drive space (without GUI) or 10 GB (with GUI).

Warning! Make sure to back up any important files from the system you will install Debian on. By installing Debian you are wiping all of the data from the drive. It only erases data on the system you are installing Debian on!

Create installation media

  1. Download the official Debian ISO

Debian 12 provides different installation media for various platforms. Download the image that matches your computer's architecture. Most of the time, this will be amd64 (this doesn't mean it has to be an AMD CPU; it can also be an Intel CPU). If you're unsure about your CPU architecture, you can search for your computer or CPU model online.

amd64

arm64

armel

armhf

i386

mips64el

mipsel

ppc64el

s390x

Source: Official Debian Website

  1. Download and install Balena Etcher

Etcher allows you to create a bootable USB drive using an ISO file. You can download it from https://etcher.balena.io.

When the download completes, open the exe and install Etcher on your system.

  1. Insert your USB drive and open Etcher

You can insert a USB drive into any free USB port on your computer or laptop.

If you want to create a bootable CD or DVD instead for some reason, insert a blank CD-R or DVD-R into your optical disk drive. Right-click the Debian ISO file and click Burn Disk Image. You can burn an ISO file to a CD or DVD using Disk Utility on Mac.

  1. Select the Debian ISO file

To do so, drag and drop the ISO file into the Balena Etcher window or click Flash from File and select the ISO file.

Balena Etcher should detect your USB drive automatically. If the correct USB drive is not listed below the flash drive icon, click Change and select your USB drive.

  1. Click Flash

This starts writing the Debian ISO file to your USB drive and makes the drive bootable.

When the flashing completes, unplug the USB drive and plug it into the machine you want to install Debian on.

Booting from a USB Drive

  1. Boot into your computer's BIOS

Reboot your computer and press the hotkey that appears at the bottom of the screen while your computer reboots to enter the BIOS. Some common hotkeys are:

  • F1 (Lenovo desktops and ThinkPad models, Sony), F10 (HP),

  • F2 (Acer, Asus, Lenovo, Dell, Origin PC, Samsung, Sony, Toshiba),

  • Del key (Acer, Asus, MSI).

If none of these keys work, Google it for your computer model. If your computer boots too quickly, you can use these steps from Windows to get to the BIOS:

  1. Click the Windows menu and select Settings.

  2. Click Update & Security on Windows 10 or System on Windows 11

  3. Click Recovery

  4. Click Restart now under "Advanced startup."

  5. Click Troubleshoot

  6. Click Advanced options

  7. Click UEFI Firmware Settings.

  8. Click Restart.

  9. Find the boot order menu

The BIOS menu looks different depending on your computer/motherboard manufacturer. You'll want to find the "Boot order" menu or similar.

💡
You can use the arrow keys to navigate the BIOS menu and press Enter to make selections.
  1. Set your USB drive/removable media first in the boot order

You'll need to ensure your computer is set to boot from the USB or CD/DVD drive before the hard drive. This ensures that your PC will know to boot from the Debian media you created instead of into the existing operating system.

  1. Save changes and exit the BIOS

Your PC will restart and automatically boot from your Debian installation media if connected. If not, it'll boot back into your primary operating system.

bul

  1. Select Graphical Install

Use the arrow key to make the selection, and then press the Enter key to select it.

💡
You can also select the regular Install option. The process is the same for both options.
  1. Select a language and region

The first three screens will ask you to choose your language, location, and keyboard region. Once you've made your selections, the installer will ask you to configure your network.

  1. Select your network interface

Depending on your computer, you may have one or two options (i.e., a wired and wireless option). Select whichever you plan on using.

If you receive an error about your Wi-Fi adapter, connect your computer to your modem or router using an ethernet cable and use a wired connection instead.
  1. Enter a hostname and domain name

The hostname is the name that identifies your computer on the network. If you have a domain name assigned to your network, you can enter it on the line. If not, just leave that line blank and select Continue.

  1. Create or skip a root password

Although you were once required to create a root (admin) account and password when installing Debian, you can now skip this step.

💡
To skip creating a root password, leave the "Set up users and passwords" screen blank and click Continue.
🧐
Skipping the root password step means sudo will automatically be set up for your user account, giving you root access. It's safer to not have a root password since you won't need to share it with other admins. You can then elevate other accounts that also need administrative access.
  1. Create a user account

Now you can create your own account, which is how you'll log in to Debian. Enter your full name (or whatever name you want to use), select Continue, and create your username and secure password.

💡
As long as you skipped adding a root account, this new account will be given sudo rights.
  1. Select a time zone and click Continue

This ensures your system clock is set properly.

  1. Select a partition option

The option you choose for partitioning depends on your needs:

  • If you just want to install Debian on existing unused drive space, select Guided – use the largest continuous free space.

  • If you only want to use Debian on this drive and not anything else, select Guided – use entire disk.

  • Select Manual if you want to retain other partitions on the computer, such as your Windows installation.

  1. Follow the on-screen instructions to partition your drive(s)

This process varies depending on how you're installing Debian. If you chose one of the Guided options, let the on-screen instructions walk you through the process. When given the option to choose a file system, select Ext4 journaling file system. When the partitioning is complete, Debian will start installing.

  • When asked to select a partition scheme, you can choose to have all files on one partition (recommended for new users), have a separate partition for your Home directory, or separate partitions for home, var, and tmp directories.

  • Once you make your selection, review the changes that will be made to your disk, click Finish partitioning and write changes to disk, and select Yes to confirm.

  • If you are asked to scan for another DVD or CD, select No and then Continue.

  1. Choose a network mirror

Select whichever country is closest to you, then select the Debian mirror archive. The first or recommended option is the best option.

💡
If you use a proxy server, enter the information when prompted. If not, leave the space blank and click Continue.
  1. Select software to install and click Continue

Select GNOME if you want a desktop environment. Make sure to select "standard system utilities." If you want to be able to connect to your Debian system remotely through SSH, select the "SSH server" option.

Once you click Continue, Debian will begin the bulk of the installation process
  1. Click Continue when the installation is complete

It can take several minutes for this to appear, depending on the speed of your computer (and network speed if you installed it over the internet). This will immediately reboot the computer into the GRUB bootloader.

  1. Select Debian GNU/Linux to boot into Debian

*Note: On never versions of Debian it auto selects the first option after 5 seconds.

It should be the first option. The GRUB bootloader was installed with Debian and will come up any time the computer is rebooted. Once you select this option, you'll be brought to the Debian login screen.

💡
If you have Windows installed and want to boot into it instead, choose Windows Boot Manager.

Congratulations, you've successfully installed Debian! Now that your system is up and running, you can start exploring the vast world of Linux. Whether you're setting up a server, developing software, or just learning more about open-source operating systems, Debian provides a stable and versatile platform. Enjoy your new Debian system!

PS: This whole article was based on WikiHow’s article, but was improved in many ways.