deprecated has asked for the wisdom of the Perl Monks concerning the following question:

The gods have smiled on me recently, and through some bizarre twist of luck, I'm getting one of the new G4 laptops. So all of a sudden I have 30GB more of actual hard disk space with which to rearrange my workstation's partition map. So, I figured I would start by backing everything up on the workstation, and get it ready for the transition to 100% server. Now, as I am going through stuff, I see that I appear to have not 1, not 2, but 3 complete perl installs. Now, I'm aware that CPAN.pm can do some sort of snapshot operation whereby it can take a picture of everything you have installed. Can I use this feature to re-install perl so that it's exactly as I left it? Also, How can I go about removing perl without hurting anything? I cant quite just rm -fr each of those directories, right? I get the feeling apache will not like it very much if i do. I keep all my code on a separate partition, so Im not too worried about losing code. I just want to make sure everything is sterile so I can keep track of what I need to back up and what I dont need to back up.

brother dep.

--
i am not cool enough to have a signature.

Replies are listed 'Best First'.
Re: Carefully uninstalling perl on unix.
by Trinary (Pilgrim) on Feb 07, 2001 at 00:29 UTC
    Autobundle is the CPAN 'snapshot' thingy. Just builds a Bundle of all the packages you have installed, and saves it to your .cpan dir. So you can copy that over to the ~/.cpan/foo/ wherever you're putting it, and it'll get all the packages you had installed...at least, everything it can find.

    doing an install of the autobundle is a lil dicey, I got a whole bunch of dependancy problems and had to go several runs through, but after that it was good. I believe it grabs newest versions of everything, don't know if that's the behaviour you want or not.

    So, autobundle++ in general, but use with caution. When I used it to do an upgrade from 5.005_03 to 5.6, it tried to install 5.6 again as a package...that's not quite what I wanted. So keep an eye on it.

    Re: removing dirs...just move them to start, update apache configs to point to new dirs, and test. Rinse, repeat until nothing depends on old stuff, and you should be good to rm -rf away.

    Good luck!

    Trinary

Re: Carefully uninstalling perl on unix.
by chipmunk (Parson) on Feb 07, 2001 at 01:28 UTC
    Note that those three directories actually correspond to two complete perl installs, not three. /usr/lib/perl5/5.00503 contains the standard modules and other library files for an install perl5.005_03; /usr/local/lib/perl5/5.6.0 contains the standard library files for an install of perl5.6.0; and /usr/local/lib/perl5/site_perl contains site specific modules and is further divided into subdirectories for the different versions of Perl. For example:
    % ls -F /usr/local/lib/perl5/site_perl/ 5.005/ 5.6.0/
    Don't forget that these are just the library files; the binary files, usually in /usr/bin or /usr/local/bin, are also an important part of a perl install. :)
Re: Carefully uninstalling perl on unix.
by sachmet (Scribe) on Feb 07, 2001 at 01:28 UTC
    Keep in mind that site_perl is not a perl install by itself, but hold all the modules that are site dependent. Within the site_perl directory, you should have two more: 5.005 and 5.6.0, which contain those libs. I wouldn't be super concerned about them as they take a grand total of 20M apiece (at least on my system, which has many optional modules installed). Besides which, any module you compiled under 5.005 but not under 5.6 will be used by 5.6 (assuming that option was enabled in configure). So I wouldn't worry about removing 5.005.