Creating a MemTest86 bootable USB Flash drive in Linux/Mac
- Download the current Memtest86 package as a Zip file from this page.
- Unzip the file. Inside the Zip there is a "disk image" file. For the free edition of MemTest86, this file is called, memtest86-usb.img
- Insert a USB flash drive into a USB slot. It needs to be at least 512MB in size.
Warning: The contents will be overwritten in the next steps.
- Determine which device the USB drive is assigned as by opening the Terminal and typing the following command. Don't get this wrong as you don't want to overwrite the wrong drive.
- Unmount all volumes on the USB drive by typing the following command:
diskutil unmountDisk <device_name>In the example above the device name is /dev/disk2
- As the root user, use the 'dd' command to write the image to the USB drive. For example,
sudo dd if=<input_file> of=<device_name> bs=4m
Note: For Ubuntu, the bs=4M must be capitalised.where:
<device_name> is the device the USB key is assigned to. Use the base device (ie. /dev/disk2) not a partition designation (ie. /dev/disk2s1). bs= block size of data transfer. Larger block sizes are faster.
<input_file> is the file path for the input image file. (E.g: ~/Downloads/memtest86-usb.img)
Warning: all data on the USB key will be lost.
3rd warning! Make sure that the device used in the dd command above is correct. The consequence of picking the wrong drive are potentially disastrous. Total and compete data loss from your hard drive, if you overwrite the wrong drive.
- When finished, Reboot your On a Mac, you need to hold down the ALT / Option key on the Mac keyboard while powering on the machine to boot from USB.
On newer Macs from 2019(*) with the Apple T2 Security Chip, you may need to change the SecureBoot settings for MemTest86 to boot. Please see the following page for instructions: https://support.apple.com/en-us/HT208330
(*) These Mac computers have the Apple T2 Security Chip:
- iMac introduced in 2020
- iMac Pro
- Mac Pro introduced in 2019
- Mac Mini introduced in 2018
- MacBook Air introduced in 2018 or later
- MacBook Pro introduced in 2018 or later
Allow booting from external drives and allow booting from non-apple software: