ISO conversion and burning: DMG, DAA, MDF, UIF, BIN, NRG
CDs and DVDs are wonderful repositories of information. Sometimes, you might want to back them up, as we previously explained. When you backup or “rip” a DVD or CD, you may choose to save a image / snapshot of it to your hard drive. Such a file is called an “ISO” and can have various formats, depending on the program used to create it. The most portable is an actual .iso file, but various programs and platforms may have their own proprietary formats which may compress or encrypt the image file. For example, Nero will create .nrg images, PowerISO will create .daa, MagicISO will create .uif, Alcohol 120% will make .mdf, whereas in the Mac world the .dmg format seems prevalent; .bin / .cue is widely used and understood, supported by most major DVD burning software and as such it poses no problem. We’ll talk about:
- 1. Windows
- 2. Mac
- 3. Linux
Sometimes you no longer have the program used to create the file but still need to access or burn your ISO image back to its optical medium. In that situation, you can either use a program known to understand, extract, use (burn) and convert a multitude of formats, or convert it to a regular .iso and burn it with a free program, such as ImgBurn or CDburnerXP.
According to developer.apple.com, under the innocuous dmg name and apparent simplicity there can be a multitude of formats:
- UDRW - UDIF read/write image
- UDRO - UDIF read-only image
- UDCO - UDIF ADC-compressed image
- UDZO - UDIF zlib-compressed image
- UDBZ - UDIF bzip2-compressed image (OS X 10.4+ only)
- UFBI - UDIF entire image with MD5 checksum
- UDRo - UDIF read-only (obsolete format)
- UDCo - UDIF compressed (obsolete format)
- UDTO - DVD/CD-R master for export
- UDxx - UDIF stub image
- UDSP - SPARSE (grows with content)
- RdWr - NDIF read/write image (deprecated)
- Rdxx - NDIF read-only image (Disk Copy 6.3.3 format)
- ROCo - NDIF compressed image (deprecated)
- Rken - NDIF compressed (obsolete format)
- DC42 - Disk Copy 4.2 image
This might force you to sometimes try more than one conversion method, though some users report having been able to use it by simply renaming it from .dmg to .iso.
1. Windows Dominion
Note that you can use most applications designed for linux (see below) on Windows by installing Cygwin. Apart from *.dmg and *.daa images, ImgBurner (linked in Sources) can burn virtually any image file do CD or DVD.
a) DMG
To be able to use a .dmg file in Windows you will have to either install commercial software (wiki links below) or use dmg2img, a free utility from vu1tur. At the command prompt and with the utility in the same directory with the .dmg file, cd to that directory, then enter at the prompt "dmg2iso filename.dmg chosenfilename.iso" replacing "filename" with the filename of your .dmg. You may then burn the resulting ISO file with ImgBurn or your favorite CD/DVD burning program.
Dmg2img can be compiled and used on other platforms as well, not just on Windows, as the author has kindly provided the source code.
b) DAA
This is a file created with PowerISO and employing some kind of compression. You might not want to install PowerISO as that is commercial software. In that situation, you need to download the free daa2iso utility from Luigi Auriemma (link below). After download, double click the executable (it has a label Application and a red, colourful icon) and choose your .daa file. Enter the name or the ISO file to create and hit save. The resulting DOS prompt will look something like this:
When done, hit ENTER (RETURN) to quit.
c) others
You may use ImgBurner to burn any disc image back to disc, except for the above. Additionally, there are several converters linked in Sources that will allow you to convert the images to ISO for free: mdf2iso (by J.P. Kloosterman), nrg2iso, nrg4iso, CDburner XP, uif2iso, bin2iso, ISO Analyzer Tool.
ISO, in general
As an ISO, it is very easy to burn the file to optical medium using ImgBurner (link in sources) or almost any other CD or DVD burning software. You may convert your difficult image file with a converter. If you prefer to use MagicISO for example, you would open the .dmg file with the program, click Properties, then uncheck Apple HFS and Apple HFS+, check ISO 9660, Joliet and UDF and finally save the resulting ISO or burn it directly. Other commercial programs may make it even easier, but remember that you will eventually have to either buy the program or stop using it.
Alternatively, you may extract the offending image with 7zip, WinRar, IZArc or a similar archiver.
Emulators
If you cannot burn or convert an image file, you might want to extract it after mounting it with a CD-ROM drive emulator.
- Virtual CDROM: only ISO
- WinCDEmu: ISO, CUE, NRG, MDS/MDF, CCD, IMG
- Daemon Tools: mdx, mds/mdf, iso, b5t, b6t, bwt, ccd, cdi, cue, nrg, pdi, isz
- MagicISO: ISO CUE MDS NRG CCD MDF BIN CIF
Be very careful, though. Although all the above are free, they are notoriously difficult to uninstall.
2. Mac World Kingdom
You may find yourself in need to burn a large DMG file and discover that your Mac has only a CD burner; if only you could burn it on your Windows computer, which has a Blue Ray / DL burner..
a) Convert DMG
To convert a *.dmg file to *.iso on a Mac, type in your terminal window:
hdiutil convert /path/to/filename.dmg -format UDTO -o /path/to/savefile.iso
You may even create a bash shell script:
#!/bin/bash
echo "Converting "$1".dmg to "$1".iso:"hdiutil convert "$1".dmg -format UDTO -o "$1".iso
mv "$1".iso.cdr "$1".iso
Save as dmg2iso and run $ chmod +x dmg2iso then use it with $ dmg2iso image (where “image” is the image file name).
Some users claim that such a “.iso” file is really a “.cdr” file and as such not fully compatible with the ISO standard. For that, they recommend using
hdiutil makehybrid -o ~/folder/[outfile] ~/folder/[source]
where folder is the folder where the .dmg file resides on your Mac.
Finally, if all else fails, try the DMG Converter program (freeware) linked below.
b) DAA
Luigi’s app works on MAC as well, so you may use it in a Terminal. There is even a GUI from twilightedge (link in Sources). If that fails, consider using the free utility from PowerISO.
3. the Free GNU Benevolent Kernel Dictatorship of Linux
You might be able to access images files such as DMG by double-clicking on them. If that does not work, try
a) DMG
sudo mount -t hfsplus -o loop thisisthefile.dmg /mnt
You might find that this does not work, so you will have to use the dmg2img utility, ignoring at first the offer to automatically mount the image:
sudo apt-get install dmg2img
dmg2img /example/example.dmg /example/example.img
sudo mkdir /media/example
sudo modprobe hfsplus
sudo mount -t hfsplus -o loop example.img /media/example
After going through the steps above, you are ready to burn the resulting file from the /media directory with a CD burning app such as Brasero.
b) DAA
Luigi’s utility covered above should work on linux as well. If you have difficulties, download DAA2ISO specifically for linux from sp.
PowerISO also provides a free Linux as well as MacOSx utility.
c) IMG + SUB + CCD
When you create an image with CloneCD, you usually have a IMG, a SUB (subchannel data) and a CCD . There are usually several files: IMG (.img) or the main data repository, the SUB (.sub) file containing subchannel data and the CCD (.ccd) text descriptor. We only need the IMG for conversion with ccd2iso:
ccd2iso /path/to/example.img /path/to/example.iso
You may also just mount the file:
sudo mkdir /media/example
sudo mount -o loop example.img /media/example
d) CUE/BIN Images
CUE/BIN (.cue/.bin) are not supported directly on linux but can be converted with bchunk:
bchunk /path/to/example.bin /path/to/example.cue /path/to/example.iso
e) MDF Images
MDF (.mdf) files are usually created by Alcohol 120%. Convert them with mdf2iso:
mdf2iso /path/to/example.mdf /path/to/example.iso
To mount the file, use:
sudo mkdir /media/examplesudo mount -o loop=/dev/loop0 /path/to/example.iso /media/example
Some people reported that even WinRAR could read MDF files, or that they can be handled by simply renaming to .bin.
f) NRG Images
Nero image (.nrg) files can be converted to ISO using nrg2iso:
nrg2iso /path/to/example.nrg /path/to/example.iso
Mount them with:
sudo mkdir /media/examplesudo mount -o loop,offset=307200 /path/to/example.nrg /media/example
All this should be simple enough. If your manipulation needs are greater, you need a program called AcetoneISO.
In our next installment, we’ll discuss how to use these utilities on a small linux install on a NAS, such as the DNS-323.
Sources / More info: vu1tur, dmg-converter, wiki-magiciso, wiki-ultraiso, wiki-poweriso, wiki-isobuster, wiki-iso-comp, any2iso, wiki-acetone-iso, acetone-official, acetone-sf, transMac, wiki-daemon, ubuntu-images, dmg, imgburn, CDburnerXP, hints-mac, softp-uif2iso-lnx, uif2iso4mac, cygwin, aluigi: daa2iso + uif2iso, sp-daa2iso, dt-lite, sp-virtclndr, sp-magiciso, sp-virtcdrom, winCDemu, DAAconvMAC, lnx-cdemu, lnx-mount, DoISO, mkisofs, nrg4iso, mdf2iso, ISOanalyzer, bin2iso, WinISO, mdf2iso, PowerISO, yt-iso
Comments
Cheers
Ron