How to Install Debian 9 Stretch – Step by Step Tutorial with Screenshots

0

Debian 9 (“Stretch“) is the latest and the current version of popular server operating system from Debian team (Debian Security team and Debian LTS team). Debian 9 has been released on 17 June 2017, and you get Long Term Support for five years.

Debian team has dedicated this version (Debian 9) to the project’s founder Ian Murdock, who passed away on 2015.

What’s new:

Let’s check, what is new in the Debian 9

  1. MariaDB replaces MySQL variants (MySQL 5.5 or 5.6)
  2. Both Firefox and Thunderbird are back to Debian and replace their debranded versions Iceweasel and Icedove which were present in Debian for more than ten years.
  3. X display system no longer requires root privileges to run.

This Debian release includes lots of updated software packages, such as:

More here.

This guide helps you to do the fresh installation of Debian 9 (Meaning that all your previous installation/data will be wiped out from hard disk)

You can also go for upgrading Debian to retain the data and configurations.

READ: How To Upgrade Debian 8 Jessie to Debian 9 Stretch

Download Debian 9 DVD from here, put the OS burned DVD into the DVD-ROM drive, change the boot sequence of your system so that it boots from DVD-ROM drive.

After booting DVD, choose “Graphic Install” to begin the Debian Installation in graphical mode.

Install Debian 9 Stretch - Installer Menu
Install Debian 9 Stretch – Installer Menu

Select a language you like to use during the installation of Debian.

Install Debian 9 Stretch - Select a Language
Install Debian 9 Stretch – Select a Language

Select your location.

Install Debian 9 Stretch - Select your Location
Install Debian 9 Stretch – Select your Location

Configure your keyboard.

Install Debian 9 Stretch - Configure your keyboard
Install Debian 9 Stretch – Configure your keyboard

Configure the network:

Set the hostname for your system. Here, enter a host name without a domain name.

Install Debian 9 Stretch - Set Hostname
Install Debian 9 Stretch – Set Hostname

Enter your domain name. If this server is on your home network, then leave it blank.

Install Debian 9 Stretch - Domain Name
Install Debian 9 Stretch – Domain Name

Set root password:

Enter a password for the root account. To have a greater security over an account, make sure a password contains a mixture of letters, numbers and special characters.

Install Debian 9 Stretch - Set root password
Install Debian 9 Stretch – Set root password

Create a new user:

Create a new, non-root user for non-administrative activities. Enter a name.

Install Debian 9 Stretch - Enter a Name
Install Debian 9 Stretch – Enter a Name

Enter a user name for the above user. This name is the actual username you use to login into the system.

Install Debian 9 Stretch - Set username
Install Debian 9 Stretch – Set username

Set a password for the user “raj“.

Install Debian 9 Stretch - Set Password
Install Debian 9 Stretch – Set Password

Select the Timezone.

Install Debian 9 Stretch - Select the timezone
Install Debian 9 Stretch – Select the timezone

Partitions Creation:

Next, choose any one of the partition methods to create partitions during the installation process.

Automatic:

  1. Guided – use entire disk: Uses full disk and creates simple partitions (without LVM) for OS installation
  2. Guided – use entire disk and set up LVM: Uses full disk and creates partitions on top of LVM.
  3. Guided – use entire disk and set up encrypted LVM: Uses full disk and creates partitions on top encrypted LVM.

Manual:

  1. Manual: Use this to create partitions of your choice. This partitioning method is for advanced users. You can also use this method to retain your previous operating systems as well as your data if you partition correctly.

For this tutorial, I am choosing a second option (Guided – use entire disk and set up LVM).

Install Debian 9 Stretch - Choose Partitioning Method
Install Debian 9 Stretch – Choose Partitioning Method

Next, select the disk you want to partition for Debian installation.

Install Debian 9 Stretch - Select the disk
Install Debian 9 Stretch – Select the disk

I am choosing to have a separate partition for /home, /var, and /tmp partitions.

Install Debian 9 Stretch - Separate partition
Install Debian 9 Stretch – Separate partition

Choose “Yes” to write changes to disk and configure LVM.

Install Debian 9 Stretch - Configure LVM
Install Debian 9 Stretch – Configure LVM

Once the changes are written to the disk, then the final disk layout will look like below.

Install Debian 9 Stretch - Final Disk Layout
Install Debian 9 Stretch – Final Disk Layout

If you are happy with the partition layout, choose “Yes” to write changes to disk.

Install Debian 9 Stretch - Write Changes to disk
Install Debian 9 Stretch – Write Changes to Disk

Once the partition creation is done, the installer will begin the installation of the base system.

Install Debian 9 Stretch - Installing base system
Install Debian 9 Stretch – Installing base system

Configure the package manager:

Choose “No” to skip the scanning of another CD or DVD.

Install Debian 9 Stretch - Scanning Another Drive
Install Debian 9 Stretch – Scanning Another Drive

Choose “No” to use a network mirror.

Install Debian 9 Stretch - Network Mirror
Install Debian 9 Stretch – Network Mirror

Choose “No” to Participate in the package usage survey.

Install Debian 9 Stretch - Package survey
Install Debian 9 Stretch – Package survey

Choose the software you want to install at the time of Debian installation. Make sure you have selected “SSH server” for remote terminal access.

If you want to install Debian Minimal server – Untick the Debian desktop environment on the following step
Install Debian 9 Stretch - Choose Softwares
Install Debian 9 Stretch – Choose Software

Debian installer is now installing software for you.

Install Debian 9 Stretch - Installing OS
Install Debian 9 Stretch – Installing OS

Choose “Yes” to install the GRUB boot loader to the master boot record.

Install Debian 9 Stretch - Install GRUB
Install Debian 9 Stretch – Install GRUB

Select the partition or disk on which you want to install the GRUB boot loader.

Install Debian 9 Stretch - Select the disk for GRUB
Install Debian 9 Stretch – Select the disk for GRUB

The installation is now complete, click “Continue” to reboot your system.

Install Debian 9 Stretch - Installation Complete
Install Debian 9 Stretch – Installation Complete

The login screen of Debian 9:

Install Debian 9 Stretch - Login Screen
Install Debian 9 Stretch – Login Screen

Debian 9 Gnome Desktop:

Install Debian 9 Stretch - Desktop
Install Debian 9 Stretch – Desktop

That’s All.

You might also like