Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #157672 > unrolled thread

Extracting directories from an ISO image, command line tool?

Started byRichard Owlett <rowlett@cloud85.net>
First post2015-09-10 15:10 +0200
Last post2015-09-23 20:10 +0200
Articles 20 on this page of 62 — 13 participants

Back to article view | Back to linux.debian.user


Contents

  Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 15:10 +0200
    Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 15:20 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 16:10 +0200
        Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 16:30 +0200
          Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 16:30 +0200
        Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 17:00 +0200
          Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 17:20 +0200
            Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 18:20 +0200
              Re: Extracting directories from an ISO image, command line tool? Hans <hans.ullrich@loop.de> - 2015-09-10 18:30 +0200
                Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 20:50 +0200
                  Re: Extracting directories from an ISO image, command line tool? Hans <hans.ullrich@loop.de> - 2015-09-10 21:10 +0200
                    Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 21:30 +0200
                  Re: Extracting directories from an ISO image, command line tool? Curt <curty@free.fr> - 2015-09-10 22:10 +0200
                    Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 23:00 +0200
                    Re: Extracting directories from an ISO image, command line tool? Lisi Reisz <lisi.reisz@gmail.com> - 2015-09-11 15:40 +0200
                    Re: Extracting directories from an ISO image, command line tool? Chris Bannister <cbannister@slingshot.co.nz> - 2015-09-11 16:50 +0200
            Re: Extracting directories from an ISO image, command line tool? Lisi Reisz <lisi.reisz@gmail.com> - 2015-09-11 15:40 +0200
    Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 15:30 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 16:20 +0200
        Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 16:30 +0200
          Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 17:40 +0200
            Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 17:50 +0200
        Re: Extracting directories from an ISO image, command line tool? Eduard Bloch <edi@gmx.de> - 2015-09-10 16:30 +0200
    Re: Extracting directories from an ISO image, command line tool? Darac Marjal <mailinglist@darac.org.uk> - 2015-09-10 15:30 +0200
      Re: Extracting directories from an ISO image, command line tool? The Wanderer <wanderer@fastmail.fm> - 2015-09-10 16:30 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 16:30 +0200
    Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-10 16:40 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-10 17:30 +0200
      Re: Extracting directories from an ISO image, command line tool? David Wright <deblis@lionunicorn.co.uk> - 2015-09-10 22:50 +0200
        Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-11 10:30 +0200
          Re: Extracting directories from an ISO image, command line tool? David Wright <deblis@lionunicorn.co.uk> - 2015-09-11 18:50 +0200
            Re: Extracting directories from an ISO image, command line tool? Curt <curty@free.fr> - 2015-09-12 10:10 +0200
            Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-12 11:00 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-13 23:20 +0200
        Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-14 00:40 +0200
          Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-14 03:00 +0200
            Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-14 10:20 +0200
              Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-14 16:40 +0200
                Narrowing down problem source - was [Re: Extracting directories from  an ISO image, command line tool?] Richard Owlett <rowlett@cloud85.net> - 2015-09-17 17:00 +0200
                  Re: Narrowing down problem source - was [Re: Extracting directories from  an ISO image, command line tool?] Steve McIntyre <steve@einval.com> - 2015-09-17 18:10 +0200
                    Re: Narrowing down problem source - was [Re: Extracting directories  from an ISO image, command line tool?] Richard Owlett <rowlett@cloud85.net> - 2015-09-18 13:20 +0200
                  Re: Narrowing down problem source "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-17 19:20 +0200
                    Re: Narrowing down problem source Richard Owlett <rowlett@cloud85.net> - 2015-09-18 14:40 +0200
                      Re: Narrowing down problem source "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-18 15:00 +0200
                        Re: Narrowing down problem source Richard Owlett <rowlett@cloud85.net> - 2015-09-18 15:40 +0200
                          Re: Narrowing down problem source "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-18 15:50 +0200
                            Re: Narrowing down problem source Richard Owlett <rowlett@cloud85.net> - 2015-09-20 22:30 +0200
                              Re: Narrowing down problem source "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-21 08:20 +0200
                                Re: Narrowing down problem source Richard Owlett <rowlett@cloud85.net> - 2015-09-21 19:00 +0200
                                  Re: Narrowing down problem source "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-21 20:30 +0200
    Re: Extracting directories from an ISO image, command line tool? David Wright <deblis@lionunicorn.co.uk> - 2015-09-10 17:10 +0200
      Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-10 19:40 +0200
    Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-11 14:10 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-11 17:40 +0200
        Re: Extracting directories from an ISO image, command line tool? Brian <ad44@cityscape.co.uk> - 2015-09-11 18:50 +0200
    Re: Extracting directories from an ISO image, command line tool? Stuart Longland <stuartl@longlandclan.id.au> - 2015-09-17 22:50 +0200
      Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-18 14:00 +0200
        Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-18 14:30 +0200
          Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-18 15:50 +0200
        Re: Extracting directories from an ISO image, command line tool? Stuart Longland <stuartl@longlandclan.id.au> - 2015-09-23 04:30 +0200
          Re: Extracting directories from an ISO image, command line tool? Richard Owlett <rowlett@cloud85.net> - 2015-09-23 16:00 +0200
            Re: Extracting directories from an ISO image, command line tool? "Thomas Schmitt" <scdbackup@gmx.net> - 2015-09-23 20:10 +0200

Page 2 of 4 — ← Prev page 1 [2] 3 4  Next page →


#157693

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-10 17:40 +0200
Message-ID<q7c78-5Cv-7@gated-at.bofh.it>
In reply to#157678
The Wanderer wrote:
> [snip]
>
> And/or similar, more-complex twiddlings if you have other
> /media/distribution* directories which you want to handle. (Note that
> this will not work as expected if the two ISOs have any pathnames in
> common.)

A problem. ALL ISO's have the same directory structures but 
different files within those directories.

>
>> Browsing man page suggests that "-extract iso_rr_path disk_path" is
>> explicitly what I'm looking for. Don't have time for a detailed read
>> right now. Thank you.
>
> You're quite welcome.
>

[toc] | [prev] | [next] | [standalone]


#157694

FromThe Wanderer <wanderer@fastmail.fm>
Date2015-09-10 17:50 +0200
Message-ID<q7cgN-5NY-7@gated-at.bofh.it>
In reply to#157693

[Multipart message — attachments visible in raw view] — view raw

On 2015-09-10 at 11:36, Richard Owlett wrote:

> The Wanderer wrote:
> 
>> [snip]
>> 
>> And/or similar, more-complex twiddlings if you have other
>> /media/distribution* directories which you want to handle. (Note
>> that this will not work as expected if the two ISOs have any
>> pathnames in common.)
> 
> A problem. ALL ISO's have the same directory structures but different
> files within those directories.

That's not a problem (as long as directory permissions are handled,
which Thomas Schmitt's more-complex commandset should address). I was
just warning about the possibility that if the file exists under the
same path in two different ISOs, one of the two would get replaced by
the other.

Thomas Schmitt's post appears to contain exactly the "similar,
more-complex twiddlings" I had in mind, plus some tweaks to address
concerns I hadn't even known existed. I've marked it as noteworthy on my
own end, for my own later reference.

-- 
   The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man.         -- George Bernard Shaw

[toc] | [prev] | [next] | [standalone]


#157682

FromEduard Bloch <edi@gmx.de>
Date2015-09-10 16:30 +0200
Message-ID<q7b1p-43t-41@gated-at.bofh.it>
In reply to#157677
Hallo,
* Richard Owlett [Thu, Sep 10 2015, 09:18:18AM]:

> >if you need to automate it as non-root it looks like you can do that
> >with orrisox (part of the xorriso package):
> >
> >orrisox -indev /path/to/file.iso -extract . -subdir
> >/path/to/output/directory
> >
> 
> Browsing man page suggests that "-extract iso_rr_path disk_path" is
> explicitly what I'm looking for. Don't have time for a detailed read right
> now. Thank you.

You could also try isodump for single files.

Regards,
Eduard.

[toc] | [prev] | [next] | [standalone]


#157675

FromDarac Marjal <mailinglist@darac.org.uk>
Date2015-09-10 15:30 +0200
Message-ID<q7a5l-2Ey-39@gated-at.bofh.it>
In reply to#157672

[Multipart message — attachments visible in raw view] — view raw

On Thu, Sep 10, 2015 at 08:06:36AM -0500, Richard Owlett wrote:
> Environment:
> Using dd I have copied physical [NO INTERNET AVAILABLE ;] Debian DVD's to
> /media/distributionA resulting in
> /media/distributionA/DVD1.iso
> /media/distributionA/DVD2.iso
> .
> .
> /media/distributionA/DVDn.iso
> 
> Goal:
> Extract pool directory (and all of its sub-directories) resulting in
> /media/distributionA/poolA/
> /media/distributionA/poolA/contrib
> /media/distributionA/poolA/main
> 
> What commands should I be looking at?

You can mount an iso using the "-o loop" option to "mount" (see the man
page under "THE LOOP DEVICE"). So, you can say, for example:

 mount -o loop /media/distributionA/DVD.iso /mnt
 cp /mnt/* /media/deistributionA/poolA/

'umount' won't need any special options to umount that device.

> TIA
> 
> 
> 
> 

-- 
For more information, please reread.

[toc] | [prev] | [next] | [standalone]


#157681

FromThe Wanderer <wanderer@fastmail.fm>
Date2015-09-10 16:30 +0200
Message-ID<q7b1o-43t-9@gated-at.bofh.it>
In reply to#157675

[Multipart message — attachments visible in raw view] — view raw

On 2015-09-10 at 10:23, Richard Owlett wrote:

> Darac Marjal wrote:
>
>> On Thu, Sep 10, 2015 at 08:06:36AM -0500, Richard Owlett wrote:
>>
>>> Environment:
>>> Using dd I have copied physical [NO INTERNET AVAILABLE ;] Debian DVD's to
>>> /media/distributionA resulting in
>>> /media/distributionA/DVD1.iso
>>> /media/distributionA/DVD2.iso
>>> .
>>> .
>>> /media/distributionA/DVDn.iso
>>>
>>> Goal:
>>> Extract pool directory (and all of its sub-directories) resulting in
>>> /media/distributionA/poolA/
>>> /media/distributionA/poolA/contrib
>>> /media/distributionA/poolA/main
>>>
>>> What commands should I be looking at?
>>
>> You can mount an iso using the "-o loop" option to "mount" (see the man
>> page under "THE LOOP DEVICE"). So, you can say, for example:
>>
>>   mount -o loop /media/distributionA/DVD.iso /mnt
>>   cp /mnt/* /media/deistributionA/poolA/
>>
>> 'umount' won't need any special options to umount that device.
> 
> Will have to check to see if that or orrisox best fits some 
> personal preferences.

'mount -o loop' is in fact what I'd do myself if I were doing this
manually; I'd only fall back to xorriso / orrisox if I needed to script
or otherwise automate the process.

(Automating it using 'mount -o loop' would only work if run as root,
AFAICT, and that's not a good idea for an automated process with
possibly-untrusted input. I wouldn't do it if I had any choice in the
matter.)

-- 
   The Wanderer

The reasonable man adapts himself to the world; the unreasonable one
persists in trying to adapt the world to himself. Therefore all
progress depends on the unreasonable man.         -- George Bernard Shaw

[toc] | [prev] | [next] | [standalone]


#157683

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-10 16:30 +0200
Message-ID<q7b1o-43t-11@gated-at.bofh.it>
In reply to#157675
Darac Marjal wrote:
> On Thu, Sep 10, 2015 at 08:06:36AM -0500, Richard Owlett wrote:
>> Environment:
>> Using dd I have copied physical [NO INTERNET AVAILABLE ;] Debian DVD's to
>> /media/distributionA resulting in
>> /media/distributionA/DVD1.iso
>> /media/distributionA/DVD2.iso
>> .
>> .
>> /media/distributionA/DVDn.iso
>>
>> Goal:
>> Extract pool directory (and all of its sub-directories) resulting in
>> /media/distributionA/poolA/
>> /media/distributionA/poolA/contrib
>> /media/distributionA/poolA/main
>>
>> What commands should I be looking at?
>
> You can mount an iso using the "-o loop" option to "mount" (see the man
> page under "THE LOOP DEVICE"). So, you can say, for example:
>
>   mount -o loop /media/distributionA/DVD.iso /mnt
>   cp /mnt/* /media/deistributionA/poolA/
>
> 'umount' won't need any special options to umount that device.

Will have to check to see if that or orrisox best fits some 
personal preferences.
Thank you.

[toc] | [prev] | [next] | [standalone]


#157685

From"Thomas Schmitt" <scdbackup@gmx.net>
Date2015-09-10 16:40 +0200
Message-ID<q7bb3-4eD-13@gated-at.bofh.it>
In reply to#157672
Hi,

my two cents:

  for i in /media/distributionA/DVD*.iso
  do
    xorriso -osirrox on:auto_chmod_on -overwrite nondir \
            -indev "$i" \
            -extract /pool /media/distributionA/poolA
  done

The setting -osirrox auto_chmod_on enables writing to
read-only directories which were created by a previous
xorriso -extract command.
This is needed especially if duplicate files overwrite
each other in such read-only directories.

One may change the permissions of the directories before
extraction.

    xorriso -osirrox on -overwrite nondir \
            -indev "$i" \
            -find /pool -type d -exec chmod u+rwx -- \
            -extract /pool /media/distributionA/poolA \
            -rollback_end

The final command -rollback_end prevents error messages
about pending changes and no output drive being acquired.

This is equivalent to
    find /media/distributionA/poolA -type d -exec chmod u+rwx '{}' ';'
after each xorriso run.


Have a nice day :)

Thomas

[toc] | [prev] | [next] | [standalone]


#157692

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-10 17:30 +0200
Message-ID<q7bXt-5rc-27@gated-at.bofh.it>
In reply to#157685
Thomas Schmitt wrote:
> Hi,
>
> my two cents:
>
>    for i in /media/distributionA/DVD*.iso
>    do
>      xorriso -osirrox on:auto_chmod_on -overwrite nondir \
>              -indev "$i" \
>              -extract /pool /media/distributionA/poolA
>    done
>
> The setting -osirrox auto_chmod_on enables writing to
> read-only directories which were created by a previous
> xorriso -extract command.
> This is needed especially if duplicate files overwrite
> each other in such read-only directories.
>
> One may change the permissions of the directories before
> extraction.
>
>      xorriso -osirrox on -overwrite nondir \
>              -indev "$i" \
>              -find /pool -type d -exec chmod u+rwx -- \
>              -extract /pool /media/distributionA/poolA \
>              -rollback_end
>
> The final command -rollback_end prevents error messages
> about pending changes and no output drive being acquired.
>
> This is equivalent to
>      find /media/distributionA/poolA -type d -exec chmod u+rwx '{}' ';'
> after each xorriso run.
>
>
> Have a nice day :)
>
> Thomas
>

Ah, I was a least worried about actual potential problems.
Off to do implied homework ;)

[toc] | [prev] | [next] | [standalone]


#157706

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2015-09-10 22:50 +0200
Message-ID<q7gX8-4c4-15@gated-at.bofh.it>
In reply to#157685
Quoting Thomas Schmitt (scdbackup@gmx.net):

>   for i in /media/distributionA/DVD*.iso
>   do
>     xorriso -osirrox on:auto_chmod_on -overwrite nondir \
>             -indev "$i" \
>             -extract /pool /media/distributionA/poolA
>   done
> 
> The setting -osirrox auto_chmod_on enables writing to
> read-only directories which were created by a previous
> xorriso -extract command.
> This is needed especially if duplicate files overwrite
> each other in such read-only directories.
> 
> One may change the permissions of the directories before
> extraction.
> 
>     xorriso -osirrox on -overwrite nondir \
>             -indev "$i" \
>             -find /pool -type d -exec chmod u+rwx -- \
>             -extract /pool /media/distributionA/poolA \
>             -rollback_end
> 
> The final command -rollback_end prevents error messages
> about pending changes and no output drive being acquired.
> 
> This is equivalent to
>     find /media/distributionA/poolA -type d -exec chmod u+rwx '{}' ';'
> after each xorriso run.

Thanks Thomas; another neat tool to try out, twice in the same week.
Even better: you wrote it!

For this particular use, I think I would use "-overwrite off" because
there ought not to be any duplicate packages in one distribution's pool
and, if there were, I'd want to check that they had identical contents
and see how come they were there.

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#157724

From"Thomas Schmitt" <scdbackup@gmx.net>
Date2015-09-11 10:30 +0200
Message-ID<q7rSy-4w9-27@gated-at.bofh.it>
In reply to#157706
Hi,

i wrote
> >     xorriso -osirrox on:auto_chmod_on -overwrite nondir \

David Wright wrote:
> For this particular use, I think I would use "-overwrite off"

I do not really know how the /pool directories of a DVD set
are supposed to be related.
When testing my proposal i did not have a full set at hand
but rather used

  for i in debian*8.1*amd*iso

which matched two ISOs in my collection of bootables:
  debian-8.1.0-amd64-netinst.iso
  debian-live-8.1.0-amd64-kde-desktop.iso

Expectably they have many /pool files in common.

If one wants to prevent overwriting but wants the xorriso
run to go on after a prevented overwrite attempt, one may
raise the abort threshold from default severity "FAILURE"
to "FATAL":

  xorriso -abort_on FATAL \
          -osirrox on:auto_chmod_on -overwrite off \
          ...

This will still emit error messages like
  xorriso : FAILURE : While restoring '/u/test/poolA/main/x/xfsprogs/xfsprogs-udeb_3.2.1_amd64.udeb' : file object exists and may not be overwritten
but courageously try to extract all other files.


The man page is huge, i confess. Everybody is invited to
ask for advise, e.g. at bug-xorriso@gnu.org .

People who use xorriso should put their favorite runs with
some comments to public places where googlers can find them.
It would be helpful to mention a few keywords which come to
the mind of the xorriso user when thinking about her/his own
use cases. (Send negative comments to upstream first ! :))


Have a nice day :)

Thomas

[toc] | [prev] | [next] | [standalone]


#157748

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2015-09-11 18:50 +0200
Message-ID<q7zGq-7k9-17@gated-at.bofh.it>
In reply to#157724
Quoting Thomas Schmitt (scdbackup@gmx.net):

> I do not really know how the /pool directories of a DVD set
> are supposed to be related.
> When testing my proposal i did not have a full set at hand
> but rather used
> 
>   for i in debian*8.1*amd*iso
> 
> which matched two ISOs in my collection of bootables:
>   debian-8.1.0-amd64-netinst.iso
>   debian-live-8.1.0-amd64-kde-desktop.iso
> 
> Expectably they have many /pool files in common.

You got me there. All I had to try with was a pair of old
lenny DVDs that I'd put by for bird-scarers for the garden.

> If one wants to prevent overwriting but wants the xorriso
> run to go on after a prevented overwrite attempt, one may
> raise the abort threshold from default severity "FAILURE"
> to "FATAL":
> 
>   xorriso -abort_on FATAL \
>           -osirrox on:auto_chmod_on -overwrite off \
>           ...
> 
> This will still emit error messages like
>   xorriso : FAILURE : While restoring '/u/test/poolA/main/x/xfsprogs/xfsprogs-udeb_3.2.1_amd64.udeb' : file object exists and may not be overwritten
> but courageously try to extract all other files.

Excellent. I hadn't yet got to that bit in the...

> The man page is huge, i confess. Everybody is invited to
> ask for advise, e.g. at bug-xorriso@gnu.org .

You know, you've put so much dir/file handling in there that
I'll be demanding a pass-through mode (no .iso) like cpio has,
for merging archives and the like :)

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#157791

FromCurt <curty@free.fr>
Date2015-09-12 10:10 +0200
Message-ID<q7O2K-360-1@gated-at.bofh.it>
In reply to#157748
On 2015-09-11, David Wright <deblis@lionunicorn.co.uk> wrote:
>> 
>> Expectably they have many /pool files in common.
>
> You got me there. All I had to try with was a pair of old
> lenny DVDs that I'd put by for bird-scarers for the garden.
>

For the cherry tree?

Sorry, but I'm rooting for the birds; what the birds are rooting for, I don't
know. Poor things, anyway. At least you could've given them a Squeeze
or two.

Oh well.

[toc] | [prev] | [next] | [standalone]


#157792

From"Thomas Schmitt" <scdbackup@gmx.net>
Date2015-09-12 11:00 +0200
Message-ID<q7OP8-41d-9@gated-at.bofh.it>
In reply to#157748
Hi,

David Wright wrote:
> I'll be demanding a pass-through mode (no .iso) like cpio has,
> for merging archives and the like :)

google ...
  http://www.gnu.org/software/cpio/manual/cpio.html#Copy_002dpass-mode

There are more simple ways to achieve this, but:

  xorriso -osirrox on -overwrite off \
          -outdev stdio:/dev/null \
          -map /u/test/cdrskin-1.3.2 /foo \
          -extract /foo /u/test/copy_of_cdrskin-1.3.2 \
          -rollback_end

  diff -r /u/test/cdrskin-1.3.2 /u/test/copy_of_cdrskin-1.3.2

  rm -r /u/test/copy_of_cdrskin-1.3.2

This gesture is uneconomic because libisofs will build a
complete directory tree of /foo in memory before xorriso
can extract the not-yet-committed files from disk to disk.

The best use case for such pack-unpack combinations is
out of reach for xorriso, anyway, because ISO 9660 needs
random access. Thus an ISO image cannot always be read
from a pipe. So xorriso cannot transmit over the net to
another xorriso which would unpack on the fly.

bsdtar does read from pipe and thus happily fails when
confronted with a multi-session ISO, where directories
are stored after older file content.
Since we have a single session ISO here, it could serve
as receiver and unpacker for a xorriso generated ISO.

But we still have to invent a good use case for this.


Have a nice day :)

Thomas

[toc] | [prev] | [next] | [standalone]


#157856

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-13 23:20 +0200
Message-ID<q8mQO-2Ba-9@gated-at.bofh.it>
In reply to#157685
Thomas Schmitt wrote:
> Hi,
>
> my two cents:
>
>    for i in /media/distributionA/DVD*.iso
>    do
>      xorriso -osirrox on:auto_chmod_on -overwrite nondir \
>              -indev "$i" \
>              -extract /pool /media/distributionA/poolA
>    done
>
> The setting -osirrox auto_chmod_on enables writing to
> read-only directories which were created by a previous
> xorriso -extract command.
> This is needed especially if duplicate files overwrite
> each other in such read-only directories.
>
> One may change the permissions of the directories before
> extraction.
>
>      xorriso -osirrox on -overwrite nondir \
>              -indev "$i" \
>              -find /pool -type d -exec chmod u+rwx -- \
>              -extract /pool /media/distributionA/poolA \
>              -rollback_end
>
> The final command -rollback_end prevents error messages
> about pending changes and no output drive being acquired.
>
> This is equivalent to
>      find /media/distributionA/poolA -type d -exec chmod u+rwx '{}' ';'
> after each xorriso run.
>
>
> Have a nice day :)
>

Things almost work. I suspect operator error of some sort.
I tend to do cut-n-paste of single physical lines rather than 
looping as in your example.

I seem to be able to extract the pool directory of the first ISO 
I process.
The second fails (see sample below). It chokes on the 2nd file 
processed. I've done multiple runs on different machines varying 
as many things as seem to make sens with essentially the same 
failure reports.

I'm running Debian 8.0 with Mate. One machine I had done an 
"expert install" {Windows XP and multiple instances of Debian] 
aimed at a approximately  minimal install. I have a second 
machine dedicated to experimenting, did a "let the installer make 
all choices" to do a clean insall using all of the hard drive.

The ISO's are derived from the purchased Debian 8.0 DVD's used to 
do installation on both machines.

SAMPLE TEST RUN:

richard@jessie:~$ xorriso -osirrox on:auto_chmod_on -overwrite 
nondir -indev /media/richard/Lexar/dvd8_1.iso  -extract /pool 
/media/richard/REPO8/test/pool
xorriso 1.3.2 : RockRidge filesystem manipulator, libburnia project.

Copying of file objects from ISO image to disk filesystem is: Enabled
xorriso : NOTE : Loading ISO image tree from LBA 0
xorriso : UPDATE : 8653 nodes read in 1 seconds
xorriso : NOTE : Detected El-Torito boot information which 
currently is set to be discarded
Drive current: -indev '/media/richard/Lexar/dvd8_1.iso'
Media current: stdio file, overwriteable
Media status : is written , is appendable
Boot record  : El Torito , ISOLINUX isohybrid MBR pointing to 
boot image
Media summary: 1 session, 1941504 data blocks, 3792m data, 11.7g free
Volume id    : 'Debian 8.0.0 i386 1'
xorriso : UPDATE : 82 files restored ( 26141k) in 1 seconds , 19.0xD
xorriso : UPDATE : 188 files restored ( 52401k) in 2 seconds , 19.3xD
.
.
.
xorriso : UPDATE : 6151 files restored (3622.2m) in 151 seconds , 
18.1xD
xorriso : UPDATE : 6264 files restored (3645.2m) in 152 seconds , 
17.4xD
xorriso : UPDATE : 6317 files restored (3660.6m) in 153 seconds = 
18.2xD
Extracted from ISO image: file 
'/pool'='/media/richard/REPO8/test/pool'
richard@jessie:~$
richard@jessie:~$
richard@jessie:~$
richard@jessie:~$ xorriso -osirrox on:auto_chmod_on -overwrite 
nondir -indev /media/richard/Lexar/dvd8_2.iso  -extract /pool 
/media/richard/REPO8/test/pool
xorriso 1.3.2 : RockRidge filesystem manipulator, libburnia project.

Copying of file objects from ISO image to disk filesystem is: Enabled
libisoburn: WARNING : ISO image size 2284052s larger than 
readable size 1941504s
xorriso : NOTE : Loading ISO image tree from LBA 0
xorriso : UPDATE : 6023 nodes read in 1 seconds
Drive current: -indev '/media/richard/Lexar/dvd8_2.iso'
Media current: stdio file, overwriteable
Media status : is written , is appendable
Media summary: 1 session, 1941504 data blocks, 3792m data, 11.0g free
Volume id    : 'Debian 8.0.0 i386 2'
libburn : SORRY : Read start address 2105202s larger than number 
of readable blocks 1941503
libisofs: FAILURE : Read error occured with IsoDataSource
xorriso : FAILURE : Cannot read all bytes from ISO file 
'/pool/contrib/f/flashplugin-nonfree-extrasound/flashplugin-nonfree-extrasound_0.0.svn2431-5_i386.deb'
xorriso : FAILURE : Cannot restore regular file to disk 
filesystem: 
'/pool/contrib/f/flashplugin-nonfree-extrasound/flashplugin-nonfree-extrasound_0.0.svn2431-5_i386.deb'
xorriso : SORRY : Restoring failed: 
'/pool/contrib/f/flashplugin-nonfree-extrasound/flashplugin-nonfree-extrasound_0.0.svn2431-5_i386.deb' 
= 
'/media/richard/REPO8/test/pool/contrib/f/flashplugin-nonfree-extrasound/flashplugin-nonfree-extrasound_0.0.svn2431-5_i386.deb'
xorriso : UPDATE : 5 files restored ( 37934b) in 1 seconds = 0.0xD
xorriso : aborting : -abort_on 'FAILURE' encountered 'FAILURE'
richard@jessie:~$
richard@jessie:~$

[toc] | [prev] | [next] | [standalone]


#157860

From"Thomas Schmitt" <scdbackup@gmx.net>
Date2015-09-14 00:40 +0200
Message-ID<q8o6d-4ig-11@gated-at.bofh.it>
In reply to#157856
Hi,

Richard Owlett wrote:
> xorriso -osirrox on:auto_chmod_on -overwrite nondir -indev /media/richard/Lexar/dvd8_2.iso  -extract /pool /media/richard/REPO8/test/pool
> ...
> libisoburn: WARNING : ISO image size 2284052s larger than readable size 1941504s

Looks like the file dvd8_2.iso is truncated.
The Primary Volume Descriptor (superblock) says the ISO has
2284052 * 2048 = 4,677,738,496 bytes, whereas libburn sees
a pseudo-drive of 1941504 * 2048 = 3,976,200,192 bytes.
It gets this size info from system function stat(2).

Check independently of xorriso by

 ls -l /media/richard/Lexar/dvd8_2.iso
 /sbin/isosize /media/richard/Lexar/dvd8_2.iso

Ask xorriso for more info by

 xorriso -indev /media/richard/Lexar/dvd8_2.iso -toc  

2284052 blocks is a plausible size for a DVD image. Max size
for DVD+RW is 2295104 blocks. So probably the file lost 700 MB
during some transfer.


Have a nice day :)

Thomas

[toc] | [prev] | [next] | [standalone]


#157864

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-14 03:00 +0200
Message-ID<q8qhH-7ka-1@gated-at.bofh.it>
In reply to#157860
Thomas Schmitt wrote:
> Hi,
>
> Richard Owlett wrote:
>> xorriso -osirrox on:auto_chmod_on -overwrite nondir -indev /media/richard/Lexar/dvd8_2.iso  -extract /pool /media/richard/REPO8/test/pool
>> ...
>> libisoburn: WARNING : ISO image size 2284052s larger than readable size 1941504s
>
> Looks like the file dvd8_2.iso is truncated.
> The Primary Volume Descriptor (superblock) says the ISO has
> 2284052 * 2048 = 4,677,738,496 bytes, whereas libburn sees
> a pseudo-drive of 1941504 * 2048 = 3,976,200,192 bytes.
> It gets this size info from system function stat(2).
>
> Check independently of xorriso by
>
>   ls -l /media/richard/Lexar/dvd8_2.iso
>   /sbin/isosize /media/richard/Lexar/dvd8_2.iso
>
> Ask xorriso for more info by
>
>   xorriso -indev /media/richard/Lexar/dvd8_2.iso -toc
>
> 2284052 blocks is a plausible size for a DVD image. Max size
> for DVD+RW is 2295104 blocks. So probably the file lost 700 MB
> during some transfer.
>


I'm seeing a pattern ;/
I've got some links "somewhere" for copying DVDs to files such 
that checksums can be verified. Suspect that info may useful.


richard@jessie:~$  ls -l /media/richard/Lexar/dvd8_2.iso
-rw-r--r-- 1 richard richard 3976200192 Sep  9 07:36 
/media/richard/Lexar/dvd8_2.iso

richard@jessie:~$  /sbin/isosize /media/richard/Lexar/dvd8_2.iso
4677738496

richard@jessie:~$  xorriso -indev /media/richard/Lexar/dvd8_2.iso 
-toc
xorriso 1.3.2 : RockRidge filesystem manipulator, libburnia project.

libisoburn: WARNING : ISO image size 2284052s larger than 
readable size 1941504s
xorriso : NOTE : Loading ISO image tree from LBA 0
xorriso : UPDATE : 6023 nodes read in 1 seconds
Drive current: -indev '/media/richard/Lexar/dvd8_2.iso'
Media current: stdio file, overwriteable
Media status : is written , is appendable
Media summary: 1 session, 1941504 data blocks, 3792m data, 11.0g free
Volume id    : 'Debian 8.0.0 i386 2'
Drive current: -indev '/media/richard/Lexar/dvd8_2.iso'
Drive type   : vendor 'YOYODYNE' product 'WARP DRIVE' revision 'FX01'
Media current: stdio file, overwriteable
Media status : is written , is appendable
Media blocks : 1941504 readable , 5780880 writable , 8064944 overall
TOC layout   : Idx ,  sbsector ,       Size , Volume Id
xorriso : WARNING : Session 1 bears ISO image size 2284052s 
larger than track size 1941504s
ISO session  :   1 ,         0 ,   1941504s , Debian 8.0.0 i386 2
Media summary: 1 session, 1941504 data blocks, 3792m data, 11.0g free
Media nwa    : 2284064s

[toc] | [prev] | [next] | [standalone]


#157870

From"Thomas Schmitt" <scdbackup@gmx.net>
Date2015-09-14 10:20 +0200
Message-ID<q8x9w-wy-3@gated-at.bofh.it>
In reply to#157864
Hi,

Richard Owlett wrote:
> richard@jessie:~$  ls -l /media/richard/Lexar/dvd8_2.iso
> -rw-r--r-- 1 richard richard 3976200192 Sep  9 07:36 /media/richard/Lexar/dvd8_2.iso
> 
> richard@jessie:~$  /sbin/isosize /media/richard/Lexar/dvd8_2.iso
> 4677738496

You will need to get a new dvd8_2.iso of at least 4677738496
bytes size. 


> I've got some links "somewhere" for copying DVDs to files such that
> checksums can be verified. Suspect that info may useful.

Depending on the DVD medium type you have to expect trailing
garbage after the end of the ISO. This has to be taken into
respect when copying, diffing, or md5summing.

I would use for copying from DVD to disk:

  blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
  echo "Byte count: $(expr $blocks '*' 2048)"

  dd if=/dev/sr0 bs=2048 count=$blocks of=dvd8_2.iso

(It would be nice if Debian's MD5SUMS would not only tell
 MD5 and image name but also the image size, or if there
 was a SIZES file.)

Error messages from dd or dvd8_2.iso turning out smaller than
the announced byte count indicate failure of copying.

If the size is ok, compute the MD5 of dvd8_2.iso

  md5sum dvd8_2.iso

If you have no checksum for the image, then eject and reload
the medium and run 

  dd if=/dev/sr0 bs=2048 count=$blocks | diff - dvd8_2.iso

in order to detect instabilities with repeated copying.
If so, then diff should report

  Binary files - and dvd8_2.iso differ


--------------------------------------------------------------

If everything stays suspiciously silent, make a damage test.

Before damaging the ISO, get the original state

  dd if=dvd8_2.iso bs=1 skip=30000 count=1 2>/dev/null | od -t x1

I get told

  0000000 00
  0000001

So byte 30000 has value 0. I replace it by a NewLine character
(value 10):

  echo | dd conv=notrunc of=dvd8_2.iso bs=1 seek=30000 count=1

Now the above tests must report mismatch.

Repair ISO:

  dd if=/dev/zero conv=notrunc of=dvd8_2.iso bs=1 seek=30000 count=1

If the original value was not 0, but hex "43":

  echo -n $'\0x43' | dd conv=notrunc of=dvd8_2.iso bs=1 seek=30000 count=1


Have a nice day :)

Thomas

[toc] | [prev] | [next] | [standalone]


#157879

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-14 16:40 +0200
Message-ID<q8D5g-xQ-13@gated-at.bofh.it>
In reply to#157870
Thomas Schmitt wrote:
> Hi,
>
> Richard Owlett wrote:
>> richard@jessie:~$  ls -l /media/richard/Lexar/dvd8_2.iso
>> -rw-r--r-- 1 richard richard 3976200192 Sep  9 07:36 /media/richard/Lexar/dvd8_2.iso
>>
>> richard@jessie:~$  /sbin/isosize /media/richard/Lexar/dvd8_2.iso
>> 4677738496
>
> You will need to get a new dvd8_2.iso of at least 4677738496
> bytes size.
>
>
>> I've got some links "somewhere" for copying DVDs to files such that
>> checksums can be verified. Suspect that info may useful.
>
> Depending on the DVD medium type you have to expect trailing
> garbage after the end of the ISO. This has to be taken into
> respect when copying, diffing, or md5summing.
>
> I would use for copying from DVD to disk:
>
>    blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
>    echo "Byte count: $(expr $blocks '*' 2048)"
>
>    dd if=/dev/sr0 bs=2048 count=$blocks of=dvd8_2.iso
>
> (It would be nice if Debian's MD5SUMS would not only tell
>   MD5 and image name but also the image size, or if there
>   was a SIZES file.)
>
> Error messages from dd or dvd8_2.iso turning out smaller than
> the announced byte count indicate failure of copying.

It appears that all of my dvd8_*.iso (except possibly dvd8_1.iso) 
were defective.
Using instructions above to create dvd8_2.iso apparently works.
Don't know what I did wrong last time around.

Thank you.

[toc] | [prev] | [next] | [standalone]


#158019 — Narrowing down problem source - was [Re: Extracting directories from an ISO image, command line tool?]

FromRichard Owlett <rowlett@cloud85.net>
Date2015-09-17 17:00 +0200
SubjectNarrowing down problem source - was [Re: Extracting directories from an ISO image, command line tool?]
Message-ID<q9IPh-6Ov-31@gated-at.bofh.it>
In reply to#157879
Richard Owlett wrote:
> Thomas Schmitt wrote:
>> Hi,
>>
>> Richard Owlett wrote:
>>> richard@jessie:~$  ls -l /media/richard/Lexar/dvd8_2.iso
>>> -rw-r--r-- 1 richard richard 3976200192 Sep  9 07:36
>>> /media/richard/Lexar/dvd8_2.iso
>>>
>>> richard@jessie:~$  /sbin/isosize /media/richard/Lexar/dvd8_2.iso
>>> 4677738496
>>
>> You will need to get a new dvd8_2.iso of at least 4677738496
>> bytes size.
>>
>>
>>> I've got some links "somewhere" for copying DVDs to files such
>>> that
>>> checksums can be verified. Suspect that info may useful.
>>
>> Depending on the DVD medium type you have to expect trailing
>> garbage after the end of the ISO. This has to be taken into
>> respect when copying, diffing, or md5summing.
>>
>> I would use for copying from DVD to disk:
>>
>>    blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
>>    echo "Byte count: $(expr $blocks '*' 2048)"
>>
>>    dd if=/dev/sr0 bs=2048 count=$blocks of=dvd8_2.iso
>>
>> (It would be nice if Debian's MD5SUMS would not only tell
>>   MD5 and image name but also the image size, or if there
>>   was a SIZES file.)
>>
>> Error messages from dd or dvd8_2.iso turning out smaller than
>> the announced byte count indicate failure of copying.
>
> It appears that all of my dvd8_*.iso (except possibly dvd8_1.iso)
> were defective.
> Using instructions above to create dvd8_2.iso apparently works.
> Don't know what I did wrong last time around.
>

I started over again. I switched to a laptop dedicated to things 
that may not work as expected. For some of my projects I 
regularly wipe the disk and do a complete reinstall of Debian. 
Currently I'm running Debian 8.0 with Mate as DE. No updates.

I used
   blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
   echo "Byte count: $(expr $blocks '*' 2048)"
   dd if=/dev/sr0 bs=2048 count=$blocks of=dvd8_2.iso
as a pattern for each DVD.

_Some_ passed your test of
  ls -l /media/richard/Lexar/dvd8_2.iso
  /sbin/isosize /media/richard/Lexar/dvd8_2.iso

Example:
  ls -l dvd8_9.iso
  /sbin/isosize dvd8_9.iso

resulted in
richard@debian:~$  ls -l dvd8_9.iso
-rw-r--r-- 1 richard richard 3976200192 Sep 16 11:50 dvd8_9.iso
richard@debian:~$
richard@debian:~$  /sbin/isosize dvd8_9.iso
4460664832

**  3976200192 <> 4460664832

I did a rerun. The only apparent change in test conditions was I 
used a different instance of Mate Terminal.

blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
echo "Byte count: $(expr $blocks '*' 2048)"
dd if=/dev/sr0 bs=2048 count=$blocks of=rerundvd9.iso
ls -l rerundvd9.iso
/sbin/isosize rerundvd9.iso

result of rerun

richard@debian:~$ blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
richard@debian:~$
richard@debian:~$ echo "Byte count: $(expr $blocks '*' 2048)"
Byte count: 4460664832
richard@debian:~$
richard@debian:~$ dd if=/dev/sr0 bs=2048 count=$blocks 
of=rerundvd9.iso
2178059+0 records in
2178059+0 records out
4460664832 bytes (4.5 GB) copied, 798.488 s, 5.6 MB/s
richard@debian:~$ ls -l rerundvd9.iso
-rw-r--r-- 1 richard richard 4460664832 Sep 17 08:26 rerundvd9.iso
richard@debian:~$
richard@debian:~$ /sbin/isosize rerundvd9.iso
4460664832

I've a gut feeling that Mate Terminal isn't redoing
   blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
every time. Nagging memories of a similar problem with either 
Win95 or Win98. Might not get to do suitable test until tomorrow.

Later.

[toc] | [prev] | [next] | [standalone]


#158025 — Re: Narrowing down problem source - was [Re: Extracting directories from an ISO image, command line tool?]

FromSteve McIntyre <steve@einval.com>
Date2015-09-17 18:10 +0200
SubjectRe: Narrowing down problem source - was [Re: Extracting directories from an ISO image, command line tool?]
Message-ID<q9JV1-bo-37@gated-at.bofh.it>
In reply to#158019
Richard Owlett wrote:
>
>I started over again. I switched to a laptop dedicated to things 
>that may not work as expected. For some of my projects I 
>regularly wipe the disk and do a complete reinstall of Debian. 
>Currently I'm running Debian 8.0 with Mate as DE. No updates.
>
>I used
>   blocks=$(expr $(/sbin/isosize /dev/sr0) / 2048)
>   echo "Byte count: $(expr $blocks '*' 2048)"
>   dd if=/dev/sr0 bs=2048 count=$blocks of=dvd8_2.iso
>as a pattern for each DVD.
>
>_Some_ passed your test of
>  ls -l /media/richard/Lexar/dvd8_2.iso
>  /sbin/isosize /media/richard/Lexar/dvd8_2.iso
>
>Example:
>  ls -l dvd8_9.iso
>  /sbin/isosize dvd8_9.iso
>
>resulted in
>richard@debian:~$  ls -l dvd8_9.iso
>-rw-r--r-- 1 richard richard 3976200192 Sep 16 11:50 dvd8_9.iso
>richard@debian:~$
>richard@debian:~$  /sbin/isosize dvd8_9.iso
>4460664832

I'll tell you what's most likely wrong - you're storing your extracted
ISO images on a FAT32 filesystem which doesn't support file sizes
larger than 4GiB. That's why DVD #1 works, it's explicitly reduced in
size to fit on a 4GB USB stick too.

-- 
Steve McIntyre, Cambridge, UK.                                steve@einval.com
"Further comment on how I feel about IBM will appear once I've worked out
 whether they're being malicious or incompetent. Capital letters are forecast."
 Matthew Garrett, http://www.livejournal.com/users/mjg59/30675.html

[toc] | [prev] | [next] | [standalone]


Page 2 of 4 — ← Prev page 1 [2] 3 4  Next page →

Back to top | Article view | linux.debian.user


csiph-web