Hi all! I was gifted a 21.5 late 2011 iMac and the hard drive has been wiped, since the online recovery doesn't work anymore and I need to reinstall everything before I start upgrading the hardware, so I can check if everything works as intended.
I only have a PC with Windows, how can I make a bootable USB, so I can reinstall high Sierra on this iMac?
Making a bootable High Sierra USB Installer Entirely From Scratch in Windows or Linux Mint (without access to Mac or App Store Installer.app) - Tutorials (The Genius Bar) | InsanelyMac
bootcamp - macOS High Sierra: Create Windows bootable Usb - Ask Different
How can I use Windows to create an OS X El Capitan or macOS Sierra USB flash drive installer from the disk image (.dmg) file downloaded from Apple? - Ask Different
Trying to make bootable usb flash drive with Mac OS high sierra 10.13.6. I have some questions
Can I create a macOS bootable USB from Windows?
Can Rufus make macOS bootable USB?
Can you install macOS on a bootable USB?
Videos
This can be done via console for Windows 10/11 iso images (Not sure about 8/7, but leave any comment if it worked for you).
Start connecting your usb drive and type diskutil list to display all connected drives.
You'll see something like:
/dev/disk0 (internal):
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme 500.3 GB disk0
1: EFI EFI 314.6 MB disk0s1
2: Apple_APFS Container disk1 500.0 GB disk0s2
/dev/disk1 (synthesized):
#: TYPE NAME SIZE IDENTIFIER
0: APFS Container Scheme - +500.0 GB disk1
Physical Store disk0s2
1: APFS Volume Macintosh HD 185.7 GB disk1s1
2: APFS Volume Preboot 47.1 MB disk1s2
3: APFS Volume Recovery 512.8 MB disk1s3
4: APFS Volume VM 4.3 GB disk1s4
/dev/disk2 (external, physical):
#: TYPE NAME SIZE IDENTIFIER
0: FDisk_partition_scheme *15.6 GB disk2
1: DOS_FAT_32 LALA 15.6 GB disk2s1
For my case, the usb drive was /dev/disk2. Knowing this, format your usb drive with:
diskutil eraseDisk MS-DOS "WINDOWS10" MBR disk2
where disk2 is the usb drive id known in the prior command and "WINDOWS10" is the volume label (to be used later).
Please double check this step, or you could delete all data in another drive.
Then mount your image with:
hdiutil mount your_windows_10_image.iso
the command will return the location of the mounted iso
/dev/disk3 /Volumes/CPRA_X64FREV_ES-MX_DV5
so finally copy all the files from the mounted iso to your usb drive:
cp -rpv /Volumes/CPRA_X64FREV_ES-MX_DV5/* /Volumes/WINDOWS10
Update:
Look closely the copied files, as if you see a message like:
cp: /Volumes/CPRA_X64FREV_ES-MX_DV5/sources/install.wim: File too large
that's because the install.wim file is larger than 4GB, too large for your just created FAT32 partition in your USB stick (back in the day I originally posted this answer, probably the file wasn't that big). In this case, you will need to slipt it and copy it with the Windows Imaging libraries. So, using Homebrew install them with:
brew install wimlib
then call after (clearly, replacing the volume folder names to yours):
wimlib-imagex split /Volumes/CPRA_X64FREV_ES-MX_DV5/sources/install.wim /Volumes/WINDOWS10/sources/install.swm 3000
and now you will have two or more files with a swm extension instead of wim, where they won't be larger than 3GB
-rwxrwxrwx 1 alter staff 2.9G 26 Nov 01:03 /Volumes/WINDOWS10/sources/install.swm
-rwxrwxrwx 1 alter staff 1.5G 26 Nov 01:08 /Volumes/WINDOWS10/sources/install2.swm
For the future search, this solution works for me:
https://joshb.github.io/2017/11/23/making-a-bootable-windows-10-usb-drive-on-macos-high-sierra/
Use TransMac, which has a 15-day trial period and works flawlessly.
In the left pane, right click the USB Drive and select Format Disk for Mac
In the left pane, right click the USB Drive and select Restore with Disk Image
Point to your .dmg (or choose All Files to select an .iso) file and click Open.
It will take a few minutes depending on size of .dmg and speed of USB drive, but once done you can pop it into your mac, hold down the option key when turning on the mac and choose the USB drive.
TransMac worked for me, but first you need to partition your USB drive with GPT. It will not work if partitioned as MBR. diskpart on Windows can do this:
diskpart
DISKPART> list disk
(Find the disk number)
DISKPART> select disk 2
Disk 2 is now the selected disk.
DISKPART> clean
DiskPart succeeded in cleaning the disk.
DISKPART> convert gpt
DiskPart successfully converted the selected disk to GPT format.
DISKPART> create partition primary
Note: Links to instructions for other versions of OS X/macOS can found here.
User Josué Mpindi posted a question, where this answer was confirmed to work for macOS Sierra in a comment. Note that where necessary, you would need to substitute Sierra references for El Capitan in the instructions.
Note: A version of this answer, which uses macOS to create the USB flash drive OS X El Capitan installer, can be found here.
Using Windows to create an USB flash drive OS X El Capitan installer requires third party software beyond just TransMac. The steps below outline one possible method for creating an USB flash drive OS X El Capitan installer using Windows and other free third party tools.
Note: These instructions will not work for Yosemite. For the correct Yosemite instructions, see this answer.
Use Microsoft Edge (or some other web browser) to download the following installers to your Downloads folder. The file names are current as of September 22, 2022. If both 32 bit and 64 bit versions are available, the 64 bit version is given in the table.
Product Use Installer Type El Capitan 10.11† Free for use on Mac computers InstallMacOSX.dmgMac Disk Image 7-Zip Free 7z2201-x64.exeApplication TransMac 15 day free trial tmsetup.zipCompressed (zipped) Folder Paragon Partition Manager Community Edition 64bit Free for personal and home use Paragon-1081-FRU_WinInstallDemo_x64_17.9.1_000.exeApplication †If you get the message “InstallMacOSX.dmg can't be download securely”, then select “Keep”, as shown below.
Install all downloads except “El Capitan 10.11”. If you wish, the installed downloads can be uninstalled from the Windows Control Panel after use.
Use a 7-Zip File Manager application window to extract the
OS X Install ESDfolder and theInstallAssistant.icnsfile to your Downloads folder. From a File Explorer window, start by navigating to your Downloads folder. In this window, right click on theInstallMacOSX.dmgMac disk image file, then select "7-Zip" > "Open archive". This should open a 7-Zip File Manager application window. In this window, right click on each file or folder in the order given in the table below, then select the corresponding action. When finished, close the 7-Zip File Manager application window.File or Folder Action Type Comment Install OS XOpen Folder InstallMacOSX.pkgOpen Inside * Package File InstallMacOSX.pkgOpen Folder InstallESD.dmgOpen Mac Disk Image File OS X Install ESDCopy To… Folder See footnote ‡ OS X Install ESDOpen Folder BaseSystem.dmgOpen Mac Disk Image File OS X Base SystemOpen Folder Install OS X El Capitan.appOpen Folder ContentsOpen Folder ResourcesOpen Folder InstallAssistant.icnsCopy To… Apple Icon Image File See footnote ‡ ‡The destination should be your Downloads folder. If this Downloads folder exists on a volume that is not NTFS formatted, then see this answer.
Insert a 16 GB or larger flash drive into an USB port. If prompted, you do not need to initialize the flash drive.
Open the TransMac application with Administrator privileges. (In other words, right click on the TransMac icon, then choose "Run as administrator" or "More" > "Run as administrator".) In the TranMac application window, take the following actions.
Select "Tools" > "Settings" from the pulldown menu. In the "General" tab of the "Settings" popup, select the same copy options as shown below.
Select
OKwhen finished.Right click on the USB flash drive icon in the treeview pane, then select "Restore with Disk Image". In the "Restore Disk Image to Drive" popup , choose to "Open" the
OS X Install ESD\BaseSystem.dmgMac disk image file in your Downloads folder as the Disk Image to restore, then select theOKbutton. Next, selectYesin the "Last Warning!" popup.
Open the Paragon Partition Manager 17 CE application. Select to resize the partition with the Apple HFS volume on the USB flash drive to maximum size, as shown below. Next, select the "Change now" button. When finished, select the "Close" button.
Next, select to change the volume label on this Apple HFS volume from "OS X Base System" to "Install El Capitan", as shown below. Next, select the "Change now" button. When finished, select the "Close" button.
When finished, close the Paragon Partition Manager 17 CE application window.
In the existing TranMac window, take the following actions.
Select "Tools" > "Refresh Drive List" from the pulldown menu.
Navigate to root folder on the USB flash drive volume labeled
Install El Capitan, as shown below.In the listview pane, right click, then select "Copy Here", as shown below.
Select to copy the
OS X Install ESD\BaseSystem.chunklistandOS X Install ESD\BaseSystem.dmgfiles in your Downloads folder. Repeat to copy theInstallAssistant.icnsfile in your Downloads folder.In the listview pane, right click on the
InstallAssistant.icnsfile, then select "Rename". Change the name to.VolumeIcon.icns. When finished, the treeview and listview panes should appear as shown below.Navigate to
System\Installationfolder on the USB flash drive labeledInstall El Capitan, as shown below.In the listview pane, right click on the
Packagesfile, then select "Delete". When prompted, select theYesbutton in the popup to confirm.In the listview pane, right click, then select "Copy Here", as shown below.
Select to copy the
OS X Install ESD\Packagesfolder in your Downloads folder. (This may take a while to complete.) When finished, the treeview and listview panes should appear as shown below.Close the TransMac window.
Use the File Explorer to delete the
OS X Install ESDfolder andInstallAssistant.icnsfile in your Downloads folder. If you wish, you can also delete the downloaded files. When finished, close the File Explorer window, then empty the Recycle Bin.
References
- How do I create El Capitan installer on a Catalina (or post-El Capitan) installed Mac for use on USB boot installer?
- TransMac Help
- Paragon Hard Disk Manager Version 17 User Manual
- Apple Disk Image Utilities
- HFSExplorer
- DMGExtractor
- dmg2img
- HFS+ for Windows
- Tar and Curl Come to Windows
- dd for Windows
- SuperDuper
- HOW TO QUICKLY CREATE A MACOS BOOTABLE USB ON WINDOWS 10
The instructions for using Windows to create an USB flash drive OS X El Capitan installer are given in my first answer. This answer addresses concerns posted by user Fred - with respect to my first answer.
My first answer used the "Copy To…" action to extract the OS X Install ESD folder to the users Downloads folder. Here, this Downloads folder is assumed to be in a NTFS formatted volume. However in a now deleted post†, Fred - stated the following.
And yes, my Downloads folder is NOT on the system drive and NOT NTFS but ExFAT. One reason for changing the Downloads directory is that my system drive is way too small for all the smaller or bigger downloads. I am convinced, quite a lot of people use non‑default system setups, for instance do not install programs on the system drive but on another partition (as I do whenever possible). ExFAT comes in handy for various reasons, of course not for program installations and things that require NTFS permissions, but for downloads and shared drives this is very good.
BTW, I believe the "system drive", that Fred - referred to, is actually called the "Windows partition" in Microsoft documentation.
In this answer, I used the "Copy To…" action to extract the OS X Install ESD folder to a dma\downloads folder I created on an exFAT formatted drive E:. I received the following popup with a single error message.
This message is repeated below.
Cannot open output file : The filename, directory name, or volume label syntax is incorrect. : E:\dma\Downloads\OS X Installer ESD\BaseSystem.dmg:com.apple.diskimages.recentcksum
By examining the string BaseSystem.dmg:com.apple.diskimages.recentcksum, one can determine this string is referring to an alternate data stream. Since exFAT does not support alternate data streams, an error message was generated. After further testing, I can state the following.
This answer and my original answer do not require any alternate data streams which can or can not be copied from the
InstallMacOSX.dmgfile downloaded from Apple.
So, if this is the only error message in the popup, then you can ignore the message and proceed with creating the USB flash drive OS X El Capitan installer.
†Actually, Fred - originally posted an answer which was edited by Fred -, then me and finally a moderator. At the time of this posting, the moderator converted the answer to a comment, then deleted the answer.