0

I'm trying to burn a dvd on a mac with an external (firewire-connected) dvd drive. I'm checking the size of the iso thus:

DVD-4:dvd_files macbook$ ls -l /tmp/hybrid.iso 
-rw-r--r--  1 macbook  wheel  8700884992 Aug 22 10:57 /tmp/hybrid.iso
DVD-4:dvd_files macbook$ ls -lh /tmp/hybrid.iso 
-rw-r--r--  1 macbook  wheel   8.1G Aug 22 10:57 /tmp/hybrid.iso

The "human-readable" size is 8.1 Gig but when i try to burn, onto an 8.4G dual-layer dvd, it says "Media does not have enough free space"

The definition of a "Gigabyte" according to Wikipedia is 1 billion bytes, so the iso size should actually be 8.7 Gig according to this definition, in which case the disk definitely isn't big enough, and it's just that the -h option to ls is misleading.

Is the discrepancy just due to the ls command using a different definition of "G" (eg 1024 Meg aka 1.07 Gig? This comes out as 8.103 which fits what ls is displaying)

Journeyman Geek
  • 133,878
Max Williams
  • 3,129

1 Answers1

6

You're hitting the age-old difference between decimal prefix GB (1000^3 bytes) and binary prefix GiB (2^30 bytes). For small numbers, the difference between the two don't matter much (for example, there is "only" a 24 bytes difference between 1 KB and 1 KiB), but for large numbers, the difference can be quite significant; there's an almost 74 million bytes difference between 1 GB and 1 GiB, for example (about 7.4%, compared to a 2.4% difference in case of KB/KiB).

We know that your ISO image file is 8700884992 bytes.

A regular size (12 cm diameter), single-side, dual-layer, recordable DVD holds 7.96 GiB, or approximately 8546984919 bytes.

Since the available 8.55 GB (7.96 GiB) is less than the needed 8.70 GB (8.10 GiB) (specifically, you're short about 154 million bytes), your system complains that the disk that you are trying to record that image to does not have the necessary amount of space.

user
  • 30,336