Making a Kali Bootable USB Drive on your Mac

Kali Linux - SeniorDA

Many people want to run a new version of Linux without the need for a new computer. The easiest way, and probably the fastest, is running Kali Linux (this actually works the same way with most distributions) is to run it from a USB drive without installing it to your internal hard drive.

This simple method has several advantages:

  • It’s fast – Once you have the distribution installed on a bootable USB drive, you can boot to the login screen in just a few seconds, vs. installing and configuring the files on your internal hard drive.
  • It’s reversible — since this method doesn’t change any of your files on your internal drive or installed OS, you simply remove the Kali USB drive and reboot the system to get back to your original OS.
  • It’s portable — you can carry the Linux USB with you at all times so you can use it on most systems in just a few seconds.
  • It’s optionally persistent — you can decide to configure your Kali Linux USB drive to have persistent storage, so your data and configuration changes are saved across reboots

In order to do this, we first need to create a bootable USB drive which has been set up from an ISO image of Kali Linux.

What You’ll Need

  1. A verified copy of the appropriate ISO image of the latest Kali build image for the target system. You’ll probably select the 64-bit version in most cases.
  2. In OS X, you will use the dd command, which is already pre-installed on your Mac.
  3. A 4GB or larger USB thumb drive.

Creating a Bootable Kali USB Drive on OS X

OS X is based on UNIX, so creating a bootable Kali Linux USB drive in an OS X environment is similar to doing it on Linux. Once you’ve downloaded and verified your chosen Kali ISO file, you use dd to copy it over to your USB stick.

WARNING: You can overwrite your internal hard drive if you do this wrong. Although this process is very easy, you should be very careful to follow the instructions.
  1. Without the target USB drive plugged into your system, open a Terminal window, and type the command diskutil list at the command prompt.
  2. This will display the device paths (look for the part that reads /dev/disk0, /dev/disk1, etc.) of the disks mounted on your system, along with information on the partitions on each of the disks.
    Kali Linux - SeniorDBA
  3. Plug in your USB device to your Mac in any open USB port, wait a few seconds, and run the command diskutil list a second time. Your USB drive will now appear in the listing and the path will most likely be the last one shown. In any case, it will be one which wasn’t present before. In this example, you can see that there is now a /dev/disk6 which wasn’t previously present.Kali Linux - SeniorDBA
  4. Unmount the drive (assuming, for this example, the USB stick is /dev/disk6 — do not simply copy this, verify the correct path on your own system!):
diskutil unmount /dev/disk6
  1. Proceed to (carefully!) image the Kali ISO file on the USB device. The following command assumes that your USB drive is on the path /dev/disk6, and you’re in the same directory with your Kali Linux ISO, which is named “kali-linux-2016.2-amd64.iso”:
sudo dd if=kali-linux-2016.2-amd64.iso of=/dev/disk6 bs=1m

Note: Increasing the blocksize (bs) will speed up the write progress, but will also increase the chances of creating a bad USB stick. 

Imaging the USB drive can take a good amount of time, over half an hour is not unusual, as the sample output below shows. Be patient and wait for the command to finish.

The dd command provides no feedback until it’s completed, but if your drive has an access indicator, you’ll probably see it flickering from time to time. The time to dd the image across will depend on the speed of the system used, USB drive itself, and USB port it’s inserted into. Once dd has finished imaging the drive, it will output something that looks like this:

2911+1 records in
2911+1 records out
3053371392 bytes transferred in 2151.132182 secs (1419425 bytes/sec)

And that’s it! You can now boot into a Kali Live Installer environment using the USB device.

To boot from an alternate drive on an OS X system, bring up the boot menu by pressing the Option key immediately after powering on the device and select the drive you want to use.

Kali Linux - SeniorDBA

Good Luck!

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s