issues with cpan perl modules
Hey Guys,
I'm trying to install some modules using cpan (for perl) and are having all sorts of issues. In particular, it seems to be complaining about the untar process: Code:
cpan[1]> install LWP I've looked all over the net for this one, a few people have referenced the error, but there are no definitive answers. Any help would be appreciated (As solving dependencies by manually downloading all the modules is a right pain the the ass!). Cheers |
Is build-essential installed?
or instead of mucking with CPAN, apt-get install libwww-perl? |
yep, build-essential is installed.
I'm a little reluctant to go down the pre-packaged perl modules path unless they have _every_ module as deb packages. I don't want to get in a situation where im using some packages and some modules I've compiled myself...it gets rather messy quickly. Using cpan is the ideal solution for me, so I'd prefer to get that working If I can. |
Certain perl modules can confuse the cpan shell.
Usually module updates and module dependencies will be installed too by cpan. Which Linux are you using ? Like Ubuntu 9.10 , CentOS 5.x etc. |
We're in the Debian forum, so I assume Debian.
I've always avoided CPAN because it's never worked well for me. |
Ok, stupid question, but have you tried this?
Code:
cpan[1]> get LWP |
perl -e 'foreach (@INC){ system("find $_ -name *.pm") }' | grep LWP.pm
or Code:
perl -MFile::Find=find -MFile::Spec::Functions -Tlwe \ 'find { wanted => sub { print canonpath $_ if /\.pm\z/ }, no_chdir => 1 }, @INC' | grep LWP ..... |
If the perl module you need isn't in an official repo you can check http://debian.pkgs.cpan.org/ , it usually works better than trying to build the modules yourself.
Or try take look at Building Debian packages of Perl modules - http://www.debian-administration.org/articles/78 |
Do you have tar installed? From the failure there is a potential that /bin/tar either doesn't exist or is a link pointing to a bad spot.
|
The error isn't specific to LWP, any module I try fails with the same reasons. Entering the directory where its working (/root/.cpan/sources/authors/id/G/GA/GAAS/) shows the file which has not been extracted despite 'extracted successfully'. tar is definitely installed :)
I ended up just using debian modules as it turns out the one I was after was included in their repo's. It'd still be nice to know why cpan doesnt work, but I suppose it's really for my own interest now. A quick google seems to suggest i'm not the only one with the issue (no solutions though). |
Using Tar:/bin/tar xvf "libwww-perl-5.834.tar":
Couldn't untar libwww-perl-5.834.tar That's the problem, it doesn't even get a chance to compile, the untar is failing, your tar is busted or your out of space in the directory its untarring in |
*
# apt-get install perl-dev perl-modules 'perl-modules' provides ' Tar.pm '. ..... |
Check kernel memory
I had the same problem on a VM. The problem was a quota on the kernel memory. As a first shot shut down all services not needed (Database, Webserver,....) and try again.
|
All times are GMT -5. The time now is 02:14 PM. |