Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Move Perl modules to new CentOS VPS

by marto (Cardinal)
on Nov 08, 2013 at 20:02 UTC ( [id://1061759]=note: print w/replies, xml ) Need Help??


in reply to Move Perl modules to new CentOS VPS

"What is the quickest way to pack my old Perl installation and move it to the new server? "

Don't. Install whatever version of perl you want elsewhere on the system and leave the vendor perl alone. Otherwise you could end up with an unstable or broken system.

It's trivial to use either perlbrew or the method descried in the README (links here). Once you have perl installed you could use cpans autobundle function to build a list of the installed modules from your existing server, and simply install the bundle it creates on your new server. Before doing so you can edit the file and remove any modules you don't want. See Re: List of Installed Perl Module in Unix Box.

Replies are listed 'Best First'.
Re^2: Move Perl modules to new CentOS VPS
by monx (Novice) on Nov 08, 2013 at 22:42 UTC
    Thanks to both marto and MLX, helpful stuff...

    So
    a) distribution's Perl installation should not really be messed around with. If needed just install an alternative version of Perl for use by my Perl apps.
    b) Use CPAN's autobundle to "create" the installed module list. Then use perlbrew on the new server to re-install based on what's on the old server. Perhaps using perl -MCPAN -e 'install Bundle::Snapshot'

    But... What about external libraries used by the various Perl modules such as GD with the libjpeg, libpng etc? Do these libraries have to be installed fresh on the new server? Is there a good way to at least get a list of such external dependencies?

    Cheers...
      Greetings,

      Should be a no brainer. You have root. So just fire up what ever flavor of application management your flavor of Linux uses -- yum, druid, slac, apt, ... and take inventory. Is GD installed? Was the package the "development" version (you'll probably want that one) while I run *BSD's. As I recall, getting all the optional libraries often wanted on a Linux box required the development packages. Anyway. If you perform this step ahead of your localized Perl install/upgrade. You shouldn't run into any difficulties that aren't easily handled.

      HTH

      --Chris

      #!/usr/bin/perl -Tw
      use Perl::Always or die;
      my $perl_version = (5.12.5);
      print $perl_version;

        FreeBSD is my personal OS ;-> (where headers & libraries are generally installed together).

        I ever so mildly get annoyed with prebuilt packages (installed via rpm|yum) on GNU/Linux whenever I have to install "x-devel" package for install of "x" package alone omits related header files. (So, does anybody know of the secret password that would install libraries and headers while installing "x" alone (short of a wrapper script)?)

      A subset of (library) dependencies can be found via ldd(1) ...

      # current-host # find /perl/root/directory -name '*.so*' -type f \ | xargs ldd
      W.R.T. external dependencies: Since your dependencies are probably on the devel packages, and this is an rpm based system, then rpm -qa | grep '\-devel' should give you a good starting point.
        Greetings, gsiems .

        Thanks
        While I have both rpm, and deb on this system (*BSD). I haven't ever had need to use but deb, and only once, a year ago.

        --Chris

        #!/usr/bin/perl -Tw
        use Perl::Always or die;
        my $perl_version = (5.12.5);
        print $perl_version;

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1061759]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (5)
As of 2024-03-29 11:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found