-   Debian (
-   -   issues with cpan perl modules (

reticent 12-02-2009 03:52 PM

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:


cpan[1]> install LWP
CPAN: Storable loaded ok (v2.18)
Going to read '/root/.cpan/Metadata'
  Database was generated on Tue, 01 Dec 2009 23:39:08 GMT
Running install for module 'LWP'
CPAN: Data::Dumper loaded ok (v2.121_14)
'YAML' not installed, falling back to Data::Dumper and Storable to read prefs '/root/.cpan/prefs'
Running make for G/GA/GAAS/libwww-perl-5.834.tar.gz
CPAN: Digest::SHA loaded ok (v5.45)
CPAN: Compress::Zlib loaded ok (v2.008)
Checksum for /root/.cpan/sources/authors/id/G/GA/GAAS/libwww-perl-5.834.tar.gz ok
CPAN: Archive::Tar loaded ok (v1.38)
Will not use Archive::Tar, need 1.00
Uncompressed /root/.cpan/sources/authors/id/G/GA/GAAS/libwww-perl-5.834.tar.gz successfully
Using Tar:/bin/tar xvf "libwww-perl-5.834.tar":
Couldn't untar libwww-perl-5.834.tar
CPAN: File::Temp loaded ok (v0.18)
CPAN: Time::HiRes loaded ok (v1.9711)
Package seems to come without Makefile.PL.
  (The test -f "/root/.cpan/build/GAAS-obLMip/Makefile.PL" returned false.)
  Writing one on our own (setting NAME to LWP)
Warning (usually harmless): 'YAML' not installed, will not store persistent state
  Had problems unarchiving. Please build manually
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install
Failed during this command:
 GAAS/libwww-perl-5.834.tar.gz                : unwrapped NO -- untar failed

It seems to suggest that the untar process completes, but checking /root/.cpan/sources/authors/id/G/GA/GAAS/ shows the tgz intact, and not extracted as the message might suggest.

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!).


AlucardZero 12-02-2009 04:20 PM

Is build-essential installed?

or instead of mucking with CPAN, apt-get install libwww-perl?

reticent 12-02-2009 04:26 PM

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 gets rather messy quickly.

Using cpan is the ideal solution for me, so I'd prefer to get that working If I can.

knudfl 12-02-2009 06:26 PM

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.

AlucardZero 12-02-2009 06:42 PM

We're in the Debian forum, so I assume Debian.

I've always avoided CPAN because it's never worked well for me.

bartonski 12-02-2009 07:38 PM

Ok, stupid question, but have you tried this?


cpan[1]> get LWP
That should try to download and untar, but I'm guessing that if it can't it will leave the tar file out there... then you can try untarring by hand, and see why it's failing.

knudfl 12-03-2009 04:03 AM

perl -e 'foreach (@INC){ system("find $_ -name *.pm") }' | grep

perl -MFile::Find=find -MFile::Spec::Functions -Tlwe \ 'find { wanted => sub { print canonpath $_ if /\.pm\z/ }, no_chdir => 1 }, @INC' | grep LWP
A missing > # apt-get install libwww-perl


craigevil 12-03-2009 11:00 PM

If the perl module you need isn't in an official repo you can check , it usually works better than trying to build the modules yourself.

Or try take look at Building Debian packages of Perl modules -

estabroo 12-04-2009 04:46 PM

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.

reticent 12-07-2009 02:12 PM

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).

estabroo 12-07-2009 04:36 PM

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

knudfl 12-08-2009 03:15 AM


# apt-get install perl-dev perl-modules

'perl-modules' provides ' '.


bananadog 01-29-2011 07:30 AM

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 03:54 PM.