Use your current OS to make Debian Stretch Install Media
Here is a relatively easy way to obtain a Debian 9.1.0 Blu-ray disk(BD) image and burn it onto a USB drive or an SD card. The Debian BD image contains all of install DVDs 1,2 and 3, so it has everything you’ll need for an air-gapped off-line installation, which I’ll explain in the next post.
You Will Need:
- USB flash drive or SD card 32GB or larger
- PC running Ubuntu/Gentoo/Fedora/Windows/Mac/etc.
- Internet connection
Step 01 - In your OS (current OS), install Jigdo.
This guide explains in detail how to install Jigdo in Ubuntu. For other Linux distros use your distro’s package manager to install jigdo. For Mac/Win follow the instructions here: http://atterer.org/jigdo
In Ubuntu open up a terminal window and install jigdo and wget by entering the following:
$ sudo apt install jigdo-file wget
Step 02 - Download the jigdo files.
When installation is complete, make a new directory to store your Debian image:
$ mkdir ~/Debian $ cd ~/Debian
The Debian BD image related files are available here:
Scroll down the list of downloads and notice the SHA512SUMS.sign file.
Download the first two files underneath the SHA512SUMS.sign file.
The files will be ending in:
Add these to your ~/Debian folder.
To expedite everything run the following commands one at-a-time to download the checksums needed:
$ cd ~/Debian $ wget https://cdimage.debian.org/debian-cd/current/amd64/jigdo-bd/SHA512SUMS.sign $ wget https://cdimage.debian.org/debian-cd/current/amd64/jigdo-bd/SHA512SUMS $ wget https://cdimage.debian.org/debian-cd/current/amd64/jigdo-bd/SHA256SUMS.sign $ wget https://cdimage.debian.org/debian-cd/current/amd64/jigdo-bd/SHA256SUMS
Next you’ll need to find and start jigdo.
Before starting jigdo you’ll need to display all of the files in your ~/Debian folder
$ ls -a
At the prompt use your mouse to select and highlight
the file ending in ‘amd64-BD-1.jigdo’, and paste it into the blank.
Hit Enter. At the ‘Files to scan’ prompt hit Enter again.
At the ‘Debian mirror’ prompt hit Enter.
Now, all you have to do is make sure not to close your terminal window.
If you do close the terminal window, or have to stop the process, simply return to your
Debian folder and restart Jigdo by running the following commands:
$ cd ~/Debian $ jigdo-lite
Hit the Enter key through all of the prompts.
Now just let jigdo run and put everything together for you.
When the process is finished you will see:
Then, if everything checks out you’ll get the go-ahead to proceed:
OK: Checksums match, image is good!
Let’s check to see that the image is there:
$ ls -a
Which should display our brand new Debian Stretch image,
ending in ‘-amd64-BD-1.iso’
Step 03 - Write the Debian image to a USB drive
Now to burn the image to the USB/SD card:
Insert the USB/SD card into a USB port on your PC.
Determine the path to the USB/SD card:
$ sudo fdisk -l
Which should display something like:
Device Boot Start End Sectors Size Id Type
/dev/sdb1 2048 60061695 60059648 28.7G 83 Linux
In my case the USB/SD card is /dev/sdb1, so that’s where I’ll burn the image to. Generally, your USB/SD card won’t ever be /dev/sda1 So you never want to mess with /dev/sda1
It’s critical that you unmount the USB/SD card: $ sudo umount /dev/sdb1 /mnt
Next sync the USB/SD card:
$ sudo sync /dev/sdb1 /mnt
Now you’re going to cat the iso image onto the USB/SD card. This can take a tremendous amount of time with USB2 or a slow SD card or USB2 SD card reader/adapter. USB3 and/or a fast SD card makes the process much faster.
Replace DEBIAN_IMAGE.iso with the iso image ending in ‘’
$ sudo su # sh -c “cat DEBIAN_IMAGE.iso>> /dev/sdb”
It may take a while, so make sure to keep the terminal window open until it’s finished writing the image.
When the image is complete you need to unmount and sync the USB/SD card:
$ sudo umount /dev/sdb1 /mnt $ sudo sync /dev/sdb1 /mnt
Then return back to your normal non-root user account: # exit
Now you have genuine Debian Stretch
Blu-ray Disk iso burned onto a USB.
Included in this amazing installer are the top 15,801 most popular Debian packages and everything you’ll need to correctly install Debian offline.