Creating Debian Wheezy Installation USB Stick

The simplest way to create a bootable USB stick for Debian installation is to use command dd to copy an ISO image to an empty USB stick.

First, connect an empty USB stick to a working Linux box, and see which device represents the stick:

$ sudo fdisk -l
...
Disk /dev/sdb: 16.0 GB, 16008609792 bytes
255 heads, 63 sectors/track, 1946 cylinders, total 31266816 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xb745c02d

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1              32    31266815    15633392    c  W95 FAT32 (LBA)

So, on my computer, /dev/sdb is the USB stick. Whatever is on it will be deleted and overwritten in this procedure, so make sure that I use a stick with large enough disk capacity specifically for this purpose.

When I use netinst installer, about 300 MB would be enough. When the access to the network is not guaranteed during the installation (e.g., the network adapter is not properly recognized by the Debian Installer), it is desired to at least use the full CD/DVD media, which would take about 4 GB (just the first medium should be enough for bare minimal installation, after which more full configuration can be resumed).

Download an ISO image for the Debian installer:

$ wget http://cdimage.debian.org/debian-cd/7.4.0/amd64/iso-cd/debian-7.4.0-amd64-netinst.iso

Then copy the ISO image to the USB stick:

$ sudo dd if=debian-7.4.0-amd64-netinst.iso of=/dev/sdb bs=4M
$ sudo sync
This entry was posted in Uncategorized and tagged , , . Bookmark the permalink.

8 Responses to Creating Debian Wheezy Installation USB Stick

  1. Guest says:

    Complete:

    sudo dd if=debian-7.4.0-amd64-netinst.iso of=/dev/sdb bs=4M; sync

    😉

  2. Richard says:

    But then your USB stick is a 300mb stick with unallocated space. You could make a new partition to make the remaining space available – but could you please explain how to make the partition that is created with the netinst image to span all of the available space on the drive?

    I like to add custom folders and load it with backups, apps, media, etc…. kinda difficult to figure this out. Will keep searching though!

    • Taro says:

      Richard — I think you cannot really do that with the way the install media is created. What’s happening is that the ISO image is an image of partition itself, and that includes the partition size. It’s not like files are copied individually after a partition is created, etc. The whole process is more like burning a read-only CD image onto a blank disk.

      If you wish to add files, you would need to add them before you create an ISO image. There are ways to do that, but that’s not the goal of this post.

  3. pian says:

    Hi,

    How to add or create multiple usb bootbale stick if we us this tutorial ?

    Many thanks.

  4. Cess says:

    Thanx, this really works

  5. rbees says:

    On my debian Testing (Strecth) system sudo is not needed. Having done this several times over the years I don’t recall that sudo has been needed in like forever.

    Multisystem will make usb’s with multiple iso’s on it, but I have not had much luck getting the install to work with them. So I just re-write the usb drive to the image I need at the time, it’s not like it takes a long time.

  6. dwight says:

    cant copy my wifi drivers to the directory firmware . this way is read only

Leave a Reply

Your email address will not be published. Required fields are marked *