I already know how to do it on Mac OS X (plenty of instructions online).
But is it possible to do it on Ubuntu? If yes, how?
I already know how to do it on Mac OS X (plenty of instructions online).
But is it possible to do it on Ubuntu? If yes, how?
As you want to create a LiveUSB you need a .iso
image to make it. The Mac image is a .dmg
file, so you must to convert this file into .iso
, and then install it.
DMG2IMG (1, 2) will convert the .dmg
image into a .iso
image. To install open a terminal and enter this command: sudo apt-get install dmg2img
With dmg2img
you will create an .img
file and this file will have the same format as an .iso
file, you just need to replace the extension.
In the terminal enter the following commands or paste the script with the necessary modifications:
# Replace "OriginalFile.dmg" with the filename including the extension
# of your file. The extension will be replaced where necessary unless
# you want to specify the filenames yourself.
filename="OriginalFile.dmg"
# Replace with your file name and it will create the IMG file
dmg2img -i "${filename}" -o "${filename%.dmg}.img"
# Note that the extension of the first file is ".img"!
mv "${filename%.dmg}.img" "${filename%.dmg}.iso"
Now you already have the .iso
image, with which you will make the LiveUSB. Several tools and answers exist to help you create bootable USB drives, some are specific to PC/MBR booting (Bootcamp) where Macs and newer PCs since Windows 8 require/support UEFI booting.
A related question: AskDifferent – Official way to obtain an OS X ISO file
why not just dd
the .img
file after conversion?
sudo dd if=/path/to/orig.img of=/dev/s**
dd
is a good program if a bit hard to understand for some, however dd
has one major drawback compared to GUI USB creator applications . Sometimes when you dd
an .img file onto a USB drive you can't reformat it if you want to reuse the USB drive. The GUI live USB programs don't have this problem.
– karel
May 01 '15 at 15:37
FORMAT SIZE ADJUSTMENT = ON
to restore the true capacity of USB drive (after dd'ing USB drive could appear as e.g. 50 MB instead of 4GB and standard built-in OS software sometimes can't restore it)
– Jake Badlands
Oct 13 '15 at 09:57
parted
to recreate the partition table on a dd
'd USB stick. It makes sense to me that some GUI tools don't support recreating the partition table and thus are stuck with whatever size was put there when dd
ing, but it would seem strange if it couldn't be done with parted, is this known not to work on any USB stick?
– Jan Segre
Oct 02 '17 at 04:05
.dmg
. I hope that my answer can be useful for you. If it does, just let me know. – Lucio Dec 06 '12 at 15:51