how to extract a file from a tardist - SGI

This is a discussion on how to extract a file from a tardist - SGI ; is there any way to extract a single file which is located into a tardist distribution? I would like to extract only a few files (cyradm for example) from fw_cyrus-imapd tardist, without having to install all the cyrus-imapd tardist and ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: how to extract a file from a tardist

  1. how to extract a file from a tardist


    is there any way to extract a single file which is located into a tardist
    distribution?
    I would like to extract only a few files (cyradm for example) from
    fw_cyrus-imapd tardist, without having to install all the
    cyrus-imapd tardist and all the dependencies associated.
    than kyou

    Rick


  2. Re: how to extract a file from a tardist

    In article ,
    Rick wrote:

    :is there any way to extract a single file which is located into a tardist
    :distribution?

    Yes, but...

    :I would like to extract only a few files (cyradm for example) from
    :fw_cyrus-imapd tardist, without having to install all the
    :cyrus-imapd tardist and all the dependencies associated.
    :than kyou

    That's not the same question.

    A tardist file is just a renamed .tar file. You can use tar
    to extract any file in it. In your example above, you could
    extract just fw_cyrus-imapd.README for example, without
    also extracting fw_cyrus-imapd.man .

    The .tar (or .tardist) file is merely a convenient way to bundle
    several files that together form an 'inst' image. If you look
    at the .tar / .tardist contents via tar -tv then you won't see
    anything even remotely close to cyradm . The individual files that
    inst / swmgr know how to install are indexed through the
    files named 'fw_cyrus-imapd' and 'fw_cyrus-imapd.idb', and
    the actual files are stored in compressed form within the
    appropriate fw_cyrus-imapd.* file such as fw_cyrus-imapd.sw
    for all files in the subsystem fw_cyrus-imapd.sw.util (or whatever
    the appropriate subsystem name is.) You don't have much hope of
    extracting just the one file yourself without using inst.


    Here's the steps to use to do what you want done:

    $ #save fw_cyrus-imapd.tardist to /tmp
    $ mkdir /tmp/inst; cd /tmp/inst
    $ tar -xvf /tmp/fw_cyrus-imapd.tardist
    $ inst -f . -r . -Y cyradm
    inst> k *
    inst> i fw_cyrus-imapd.sw
    inst> set rulesoverride on
    inst> go
    inst> exit
    $ mv `find . -name cyradm -print` /tmp/cyradm #or other convenient location
    $ cd -
    $ rm -r /tmp/inst /tmp/fw_cyrus-imapd.tardist

    The -Y cyradm parameter restricts to only installing cyradm .
    You might have to specify a fuller path (no leading slash!!) such as
    -Y usr/freeware/bin/cyradm

    The -r . tells inst to use the current directory (aka '.') as the
    "root" of the install tree, so that you do not interfer with your
    live installation. Although with the -Y parameter, inst will only
    load the files you specify from the product images, inst will
    also create the whole substructure for maintaining install information
    such as /tmp/inst/var/inst/ . The temporary directory contains
    that infrastructure; you remove it at the end.


    You *cannot* do all of this within swmgr by the usual procedure
    of going to the freeware site and asking to download the .tardist
    and having swmgr automatically invoked by your browswer .
    It -is- possible to use set restrictions within inst or
    swmgr instead of using the -Y command line parameter, but it is
    NOT possible to use set target /tmp/inst from within inst / swmgr
    to set the root directory to install into -- 'target' is a read-only
    variable once inst / swmgr has started up, so if you were to
    do this within swmgr upon an automatically unbundled .tardist
    file then you would be working with the live installation
    database instead of with a throw-away installation database.
    --
    *We* are now the times. -- Wim Wenders (WoD)

  3. Re: how to extract a file from a tardist


    thank you very much for the usefull explanation

    Rick

    In article , Walter Roberson wrote:
    > In article ,
    > Rick wrote:
    >
    >:is there any way to extract a single file which is located into a tardist
    >:distribution?
    >
    > Yes, but...
    >
    >:I would like to extract only a few files (cyradm for example) from
    >:fw_cyrus-imapd tardist, without having to install all the
    >:cyrus-imapd tardist and all the dependencies associated.
    >:than kyou
    >
    > That's not the same question.
    >
    > A tardist file is just a renamed .tar file. You can use tar
    > to extract any file in it. In your example above, you could
    > extract just fw_cyrus-imapd.README for example, without
    > also extracting fw_cyrus-imapd.man .
    >
    > The .tar (or .tardist) file is merely a convenient way to bundle
    > several files that together form an 'inst' image. If you look
    > at the .tar / .tardist contents via tar -tv then you won't see
    > anything even remotely close to cyradm . The individual files that
    > inst / swmgr know how to install are indexed through the
    > files named 'fw_cyrus-imapd' and 'fw_cyrus-imapd.idb', and
    > the actual files are stored in compressed form within the
    > appropriate fw_cyrus-imapd.* file such as fw_cyrus-imapd.sw
    > for all files in the subsystem fw_cyrus-imapd.sw.util (or whatever
    > the appropriate subsystem name is.) You don't have much hope of
    > extracting just the one file yourself without using inst.
    >
    >
    > Here's the steps to use to do what you want done:
    >
    > $ #save fw_cyrus-imapd.tardist to /tmp
    > $ mkdir /tmp/inst; cd /tmp/inst
    > $ tar -xvf /tmp/fw_cyrus-imapd.tardist
    > $ inst -f . -r . -Y cyradm
    > inst> k *
    > inst> i fw_cyrus-imapd.sw
    > inst> set rulesoverride on
    > inst> go
    > inst> exit
    > $ mv `find . -name cyradm -print` /tmp/cyradm #or other convenient location
    > $ cd -
    > $ rm -r /tmp/inst /tmp/fw_cyrus-imapd.tardist
    >
    > The -Y cyradm parameter restricts to only installing cyradm .
    > You might have to specify a fuller path (no leading slash!!) such as
    > -Y usr/freeware/bin/cyradm
    >
    > The -r . tells inst to use the current directory (aka '.') as the
    > "root" of the install tree, so that you do not interfer with your
    > live installation. Although with the -Y parameter, inst will only
    > load the files you specify from the product images, inst will
    > also create the whole substructure for maintaining install information
    > such as /tmp/inst/var/inst/ . The temporary directory contains
    > that infrastructure; you remove it at the end.
    >
    >
    > You *cannot* do all of this within swmgr by the usual procedure
    > of going to the freeware site and asking to download the .tardist
    > and having swmgr automatically invoked by your browswer .
    > It -is- possible to use set restrictions within inst or
    > swmgr instead of using the -Y command line parameter, but it is
    > NOT possible to use set target /tmp/inst from within inst / swmgr
    > to set the root directory to install into -- 'target' is a read-only
    > variable once inst / swmgr has started up, so if you were to
    > do this within swmgr upon an automatically unbundled .tardist
    > file then you would be working with the live installation
    > database instead of with a throw-away installation database.


+ Reply to Thread