Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses

moving a perl CPAN installation

by moazza (Initiate)
on May 15, 2012 at 10:53 UTC ( #970597=perlquestion: print w/replies, xml ) Need Help??
moazza has asked for the wisdom of the Perl Monks concerning the following question:

I have a machine which has a Perl CPAN installation (built in 2005). I want to move this installation on to a newly built machine. Is it possible to use an scp to move a CPAN installation on to the new machine ?

Is there a script to find out a CPAN inventory of the machine and to move the installation on to the other machine.

Note that the source machines are not the most brilliantly documented.

All I should have added, is that both machines do not have internet access.

So, When i download a CPAN Module, i need to download the machine and move to the server before installing.

Replies are listed 'Best First'.
Re: moving a perl CPAN installation
by marto (Archbishop) on May 15, 2012 at 11:01 UTC

    Consider using cpans autobundle to export the module list from the source machine:

    cpan> autobundle [long list of Modules/versions] Wrote bundle file C:\strawberry\cpan\Bundle\

    Transfer the file to the new system (note the path) and install:

    cpan> install
Re: moving a perl CPAN installation
by sundialsvc4 (Abbot) on May 15, 2012 at 12:31 UTC

    I’d like to discuss that ... because in my experience autobundle installation on a pristine machine doesn’t work as ... well ... as it properly should.

    The problem seems to be that autobundle knows absolutely nothing at all about prerequisites.   It does not order the list of installs into a sequence that would cause the subsequent installation to proceed as smoothly as, at least, I think it should.   In a previous thread on this forum (which I have not looked up) I was given a script that someone had cobbled-together to reprocess the autobundle list.   But I wonder, why hasn’t that become “official,” even as an option?

    If you configure CPAN to follow dependencies, it does tend to work better, but even so, early installs may proceed in certain ways because optional prerequisites (e.g. YAML::Syck or even YAML itself) have not yet appeared on the (alphabetized?) list.   Of course we know that some dependencies are basically circular anyway.   But even so, to me, autobundle has earned a grade of “needs improvement” for a long time on this score.

    What do you think?   Why isn’t it much easier, and what can be done to make it so?

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://970597]
Front-paged by Corion
usemodperl gained... A NEW CAR! Thank you vroom :-)

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2018-06-21 01:42 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (117 votes). Check out past polls.