A file with the extension '.dmg' (an abbreviation for ''disk image'') uses a
disk image format commonly found on
Mac OS X. The format allows secure password protection as well as
file compression and hence serves both security and file distribution functions. Its most common function is the distribution of
software over the Internet. When opened, DMG files are "
mounted" as a drive within the
Finder.
DMG files can be easily created (with or without
encryption) using utilities that are included in OS X:
Disk Utility in
Mac OS X v10.4 and
10.3 or
Disk Copy in earlier versions. These utilities also use DMG files as images for burning CDs and DVDs. DMG files may also be managed via the
command line using the
hdiutil utility.
DMG files are published with a
MIME type of ''application/x-apple-diskimage''. As many web server administrators tend to be less knowledgeable about Apple-specific file types, this MIME type is often not set, resulting in the user experience of attempting to download DMG files as text directly to the browser window, forcing the use of a control-click or similar workaround to download the file. For this reason, DMG files may be distributed as
bzip2 (.dmg.bz2) or
ZIP (.dmg.zip) files. These wrappers typically don't compress the file further, but rather help ensure that the files are handled correctly by the server and browser software.
Utilities exist to convert DMG files into
ISO images, however, DMG files do often contain other types of disk images such as
HFS+ volumes.
With Mac OS X 10.2.3, Apple introduced Internet-Enabled Disk Images. With these images the contents of the disk image are automatically copied and the image file discarded.
[1]
To open this kind of file in Windows, several programs such as Acute Systems TransMac,
Daemon Tools,
UltraISO or
IsoBuster can be used.
In Linux, the file can be burned to cd/dvd using the program
cdrecord or directly mounted to a mountpoint (e.g. mount -o loop,ro -t hfsplus imagefile.dmg /mnt/mountpoint).
See also
★
Installer (Mac OS X)
★
cloop, a similar disc image format designed for Linux
LiveCDs
★
Universal Disk Image Format (UDIF)
References
★
Apple Developer Connection A Quick Look at PackageMaker and Installer
★
O'Reilly Mac DevCenter Tip 16-5. Create a Disk Image from a Directory in the Terminal