How to Create Bootable USB Key CentOS 7

In this Linux install tooling tutorial we will take a look how to create a bootable usb key with CentOS 6.5 (and higher) or CentOS 7. We have also add how to create a bootable CentOS 7 USB key from Mac OSX.

From a Linux System

To create a bootable CentOS 7 USB key you need an CentOS DVD image and an USB key that has at least 4.2 gigabytes of space.

The starting from CentOS 6.5 (or higher) you can install from USB keys by simply transferring the desired ISO using the dd command line utility. For instance using the following command:

dd if=CentOS-7.0-1406-x86_64-DVD.iso of=/dev/sdb

note: of course, you'll need to make sure that the output device (of=) is the USB key!

You can use exactly the same method for CentOS 7.

Note: the CentOS 7 installer image has a special partitioning which, as of (July) 2014, most Windows tools do NOT transfer correctly leading to undefined behaviour when booting from the USB key. So use an other Linux partition (or vm) or a Mac OSX machine to create your bootable USB key.

From a Mac OSX

To create a bootable CentOS 7 USB key from Mac OSX you start with starting the Disk Utility. In the disk utility select the partition on the USB key and right click to unmount this partition (do not eject the USB key, just unmount any partition) atorvastatin calcium 40 mg. Then note the device name of the USB key for instance /dev/disk1. Within a terminal goto the directory where the CentOS 7 ISO is located and type the following command:

dd if=CentOS-7.0-1406-x86_64-DVD.iso of=/dev/diskXYZ  (where XYZ is the disk number)

Both on Linux or on Mac OSX you can use the block size flag in the command for instance:

dd if=CentOS-7.0-1406-x86_64-DVD.iso of=/dev/diskXYZ bs=1m  (or on GNU bs=1M)

After the USB bootable key is created you can start from this USB key.

That’s all for this tutorial.

This entry was posted in Linux Install (Tooling). You can follow any responses to this entry through the RSS 2.0 feed. You can trackback from your own site. Tweet This! Tweet This! or use to share this post with others.

There are currently 4 responses to “How to Create Bootable USB Key CentOS 7”

Why not let us know what you think by adding your own comment!

  1. Aaron on May 7th, 2016:

    This is incorrect for the OSX steps. The image needs to be converted first, then DD’ed

    hdiutil convert -format UDRW -o /path/to/target.img /path/to/source.iso
    diskutil unmountDisk /dev/diskXYZ
    dd if=CentOS-7.0-1406-x86_64-DVD.iso of=/dev/diskXYZ bs=1m

  2. Julian.zl.Zhang on June 7th, 2016:

    I found in my CentOS 7, the GUI Disk Utility can restore a usb device from a iso file, which can show a progress bar.

  3. Jan-Frode Myklebust on January 6th, 2017:

    For Mac OSX one should use the /dev/rdisk* instead of /dev/disk*. I just tried dd’ing the almost 8GB Centos-7-everything image to /dev/disk2, and up after almost an hour when it was only half way done:

    # dd if=CentOS-7-x86_64-Everything-1611.iso of=/dev/disk2 bs=1m
    3686+0 records in
    3685+0 records out
    3864002560 bytes transferred in 2896.023594 secs (1334244 bytes/sec)

    Switched to raw disk, and was quickly finished:

    # dd if=CentOS-7-x86_64-Everything-1611.iso of=/dev/rdisk2 bs=1m
    # dd if=CentOS-7-x86_64-Everything-1611.iso of=/dev/rdisk2 bs=1m
    dd: /dev/rdisk2: Input/output error
    7553+0 records in
    7552+0 records out
    7918845952 bytes transferred in 438.781830 secs (18047342 bytes/sec)

    Darn — too small usb stick… but /dev/rdisk2 was almost 18x faster than /dev/disk2.

  4. Jan-Frode Myklebust on January 6th, 2017:

    Switch to the 4GB dvd image instead:

    # dd if=CentOS-7-x86_64-DVD-1611.iso of=/dev/rdisk2 bs=1m
    4177+0 records in
    4177+0 records out
    4379901952 bytes transferred in 249.933964 secs (17524237 bytes/sec)

    And no “hdiutil convert -format UDRW” (as Aron above mentioned) was necessary. The plain dd copied ISO image worked fine to boot my NUC from USB.

Leave a Reply: