Misplaced Pages

IMG (file format): Difference between revisions

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
Browse history interactively← Previous editNext edit →Content deleted Content addedVisualWikitext
Revision as of 06:53, 8 May 2013 editYobot (talk | contribs)Bots4,733,870 editsm WP:CHECKWIKI error fixes using AWB (9120)← Previous edit Revision as of 12:50, 8 June 2013 edit undoMcoupal (talk | contribs)Extended confirmed users5,863 editsNo edit summaryNext edit →
Line 27: Line 27:
* ] supports reading IMG files for creating ]s. * ] supports reading IMG files for creating ]s.
* ] allows manipulation of ] floppy disk images in ] systems. * ] allows manipulation of ] floppy disk images in ] systems.
* Programs such as ''dsktrans'' from the ''LibDsk''<ref></ref> suite of command-line tools (available for for ], ], and ]) will convert between different raw disk image formats. * Programs such as ''dsktrans'' from the ''LibDsk''<ref></ref> suite of command-line tools (available for ], ], and ]) will convert between different raw disk image formats.
* ] can be used in ] to create raw disk image files of disks. * ] can be used in ] to create raw disk image files of disks.
* ] uses IMG files as its default format for ] disk images, calling the format simply "raw". * ] uses IMG files as its default format for ] disk images, calling the format simply "raw".

Revision as of 12:50, 8 June 2013

IMG file format may refer to several different and incompatible file formats, which just have the use of the .img file extension in common:

This article will focus on the first format indicated above, raw disk image files that use the .img extension.

IMG raw disk image format

The .img file extension is used by files called disk images, which contain raw dumps of a magnetic disk. Since a raw image consists of a sector-by-sector binary copy of the source medium, the actual format of the file contents will depend on the file system of the disk from which the image was created (such as a version of FAT). The .img file extension was originally use for floppy disk raw disk images only, though it is currently used to refer to hard drive disk images as well.

A similar file extension, .ima, is used by some tools to refer to the same type of raw disk image files. A variant of the format is called IMZ, and consists of a gzipped version of a raw disk image. These files use the .imz file extension, and are commonly found in compressed images of floppy disks created by WinImage.

The file size of a raw disk image will always be a multiple of the sector size — generally 512 bytes for floppy disks and hard drives, but other sizes such as 128 and 1024 exist. More precisely the file size corresponds to Cylinders×Heads×(Sectors per track)×(Sector size), e.g., 1440KB=80×2×18×512 for 80 cylinders (tracks) and 2 heads (sides) with 18 sectors per track. A typical raw disk image of a disk begins with a FAT boot sector.

Raw disk images of optical media (such as CDs and DVDs) contain a raw image of all the tracks in a disc (which can include audio, data and video tracks). In some cases these images use the .img file extension, such as in the CCD/IMG format. The .bin file extension is also used for the same type of images in some formats, such as in the CUE/BIN format. This images usually include not only the data from each sector in an optical disc, but the control headers and error correction fields for each sector as well (the exact contents of the image files are described in the accompaning CCD or CUE descriptor files).

A similar format are ISO images, which commonly use the .iso file extension, but sometimes use the .img file extension as well. They are similar to the raw optical disc images mentioned previously, but contain only one track with computer data obtained from an optical disc (not multiple tracks, nor audio or video tracks). They also do not contain the control headers and error correction fields that raw disc images usually store. Their internal format follows the structure of an optical disc file system such as ISO 9660 (for CDs) or UDF (for DVDs). The CUE/BIN and CCD/IMG formats support using ISO images instead of raw disc images as well, though this is not their default structure.

Tools

The raw IMG file format is used by several tools:

  • Tools such as RaWrite and WinImage use the IMG disk image format to read and write floppy disk images.
  • Programs such as ImDisk and Virtual Floppy Drive can mount a raw image of a floppy disk to emulate a floppy drive under Microsoft Windows.
  • Nero Burning ROM supports reading IMG files for creating bootable CDs.
  • mtools allows manipulation of MS-DOS floppy disk images in Unix systems.
  • Programs such as dsktrans from the LibDsk suite of command-line tools (available for Linux, MS-DOS, and Microsoft Windows) will convert between different raw disk image formats.
  • dd can be used in Linux to create raw disk image files of disks.
  • Qemu uses IMG files as its default format for hard drive disk images, calling the format simply "raw".

References

  1. GEM Raster File Format description
  2. LibDsk suite of tools for accessing discs and disc image files
Disk image file formats
Comparison of disc image software
Optical discs
Hard disks
Floppy disks
CDDADisc Description Protocol
Convention: Any item in this table that has the form of "A+B" or "A+B+C" indicates a disk format that spans multiple files, where A contains the bulk of the data, and B and C are sidecar files.
Categories: