Re: mkisofs -M makes no attempt to reconstruct multi-extent files
Andy Polyakov <appro@fy.chalmers.se> wrote:
> $ ./mkisofs -v
> mkisofs 2.01.01a39 ...
>
> Consider creating say 5GiB file and mastering an image:
>
> $ touch 5G.0
> $ perl -e 'truncate("5G.0",5*1024*1024*1024)'
> $ ./mkisofs -iso-level 3 5G.0 > 1st.iso
>
> One does not have to wait till mkisofs completes, just press ctrl-c as
> soon as progress indicator goes off and examine directory table [in hex
> editor]. Directory table in 1st.iso contains following entries:
>
> file name flags data length location of extent
> 5G.0;1 0x80 4GB-2KB X
> 5G.0;1 0x00 5GB-(4GB-2KB) X+0x200000-1
>
> This table describes contiguous 5GiB large file named 5G.0 consisting of
> two extents. X is extent beyond directory table in 1st.iso. So far so
> good. Now throw in another 5GiB file into second session:
>
> $ touch 5G.1
> $ perl -e 'truncate("5G.1",5*1024*1024*1024)'
> $ ./mkisofs -C 16,2621614 -M 1st.iso -iso-level 3 5G.1 > 2nd.iso
>
> Again, one does not have to wait till mkisofs completes, just press
> ctrl-c as soon as progress indicator goes off and examine directory
> table [in hex editor]. Directory table in 2nd.iso comes out corrupted:
>
> file name flags data length location of extent
> 5G.0;1 0x80 4GB-2KB X
> 5G.1;1 0x80 4GB-2KB Y
> 5G.1;1 0x00 5GB-(4GB-2KB) Y+0x200000-1
> 5G000.0;1 0x00 5GB-(4GB-2KB) X+0x200000-1
>
> This table describes fragmented 9GB-2KB file named either 5G.0 or
> 5G.1[?] and 1GB+2KB file named 5G000.0. Y is extent beyond directory
> table in 2nd.iso. Correct table for 2nd.iso would be:
>
> file name flags data length location of extent
> 5G.0;1 0x80 4GB-2KB X
> 5G.0;1 0x00 5GB-(4GB-2KB) X+0x200000-1
> 5G.1;1 0x80 4GB-2KB Y
> 5G.1;1 0x00 5GB-(4GB-2KB) Y+0x200000-1
You used mkisofs incorrectly and you seem to missinterpret the results
from the tool you used to list ISO-9660 directories.
You did however find a bug. It seems that mkisofs for some reason assigned "new"
block addresses for old files. It will take some time to find the reason as
there are 4 possible different places that could be the problem.
Jörg
--
EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
js@cs.tu-berlin.de (uni)
schilling@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/
URL: http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily
Reply to: