Created
October 17, 2014 07:50
-
-
Save Passw/68c5a61366426213b2ad to your computer and use it in GitHub Desktop.
HowTo : create a bootable ISO of Yosemite 10.10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
# IN Mac OS X Mavericks 10.9.1 to create bootable ISO for Mac OS X Yosemite 10.10.0 | |
# ************************************************************** | |
# Install OS X Mavericks.app ==> Bootable_OS_X_Yosemite_10.10.0.iso | |
# ************************************************************** | |
# hdiutil attach Install\ OS\ X\ Yosemite.app.dmg | |
# Mount the installer image | |
# cd /Volumes/Установка\ OS\ X\ Yosemite/Install\ OS\ X\ Yosemite.app/Contents/SharedSupport/ | |
cd /Applications/Install\ OS\ X\ Yosemite.app/Contents/SharedSupport | |
hdiutil attach InstallESD.dmg -noverify -nobrowse -mountpoint /Volumes/install_app | |
# Convert the boot image to a sparse bundle | |
hdiutil convert /Volumes/install_app/BaseSystem.dmg -format UDSP -o /tmp/Yosemite | |
# Increase the sparse bundle capacity to accommodate the packages | |
hdiutil resize -size 8g /tmp/Yosemite.sparseimage | |
# Mount the sparse bundle for package addition | |
hdiutil attach /tmp/Yosemite.sparseimage -noverify -nobrowse -mountpoint /Volumes/install_build | |
# Remove Package link and replace with actual files | |
rm /Volumes/install_build/System/Installation/Packages | |
cp -rp /Volumes/install_app/Packages /Volumes/install_build/System/Installation/ | |
# fix Mac OS X Yosemite Undefined error : 0 | |
defaults write com.apple.finder AppleShowAllFiles TRUE | |
killall Finder | |
# You need to copy [the hidden] BaseSystem.dmg and BaseSystem.chunklist to the root of your install USB. | |
# COPY THIS TWO FILES (It is the solution for the common error - The operation couldn't be completed. Undefined error: 0) | |
cp /Volumes/install_app/BaseSystem.chunklist /Volumes/install_build/BaseSystem.chunklist | |
cp /Volumes/install_app/BaseSystem.dmg /Volumes/install_build/BaseSystem.dmg | |
# Unmount the installer image | |
hdiutil detach /Volumes/install_app | |
# Unmount the sparse bundle | |
hdiutil detach /Volumes/install_build | |
# Resize the partition in the sparse bundle to remove any free space | |
hdiutil resize -size `hdiutil resize -limits /tmp/Yosemite.sparseimage | tail -n 1 | awk '{ print $1 }'`b /tmp/Yosemite.sparseimage | |
# Convert the sparse bundle to ISO/CD master | |
hdiutil convert /tmp/Yosemite.sparseimage -format UDTO -o /tmp/Yosemite | |
# Remove the sparse bundle | |
rm /tmp/Yosemite.sparseimage | |
# Rename the ISO and move it to the desktop | |
mv /tmp/Yosemite.cdr ~/Yosemite.iso | |
cp ~/Yosemite.iso /Volumes/VMware\ Shared\ Folders/Downloads/Bootable_OS_X_Yosemite_10.10.0.iso |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Works like a charm! Thank you.