Tags:
create new tag
, view all tags

Question

Installing on a system to which I don't have root access, I got the following problem when attempting to access the testenv script

Perl Module(s) missing

Warning: Essential module CGI not installed - please check your Perl installation, including the setting of @INC, and re-install Perl if necessary.

Warning: Essential module CGI::Carp not installed - please check your Perl installation, including the setting of @INC, and re-install Perl if necessary.

@INC setting:
../lib
/usr/lib/perl5/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/5.8.0
/usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/site_perl/5.8.0
/usr/lib/perl5/site_perl
/usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi
/usr/lib/perl5/vendor_perl/5.8.0
/usr/lib/perl5/vendor_perl
.

Thought I'd document this solution for other people.

Environment

TWiki version: TWikiRelease01Feb2003
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: Red Hat Linux 8.0, Kernel 2.4.18
Web server: unknown
Perl version: 5.8.0
Client OS: n/a
Web Browser: n/a

-- AndyPryke - 04 Dec 2003

Answer

I solved this by downloading the CGI: module from CPAN: http://www.cpan.org/authors/id/L/LD/LDS/CGI.pm-3.00.tar.gz

I then followed the CPAN module install instructions at: http://www.cpan.org/modules/INSTALL.html installing it into a sub-dir of my home directory ("/home/people/anp/dev/perl/lib/CGI.pm-3.00")

Note that as I didn't have root access, the "install" script fails. If you are root, I guess it should work and you won't need to modify setlib.cfg.

I then update the TWiki file twiki/bin/setlib.cfg, changing the line:

# $localPerlLibPath = '';
to read
$localPerlLibPath = '/home/people/anp/dev/perl/lib/CGI.pm-3.00';

I then re-loaded the testenv script in my browser and it worked.

System version info:

Perl version : 5.8.0

uname -a gives this output:

Linux somemachinename 2.4.18-14smp #1 SMP Wed Sep 4 12:34:47 EDT 2002 i686 i686 i386 GNU/Linux


Thanks for documenting this - however, CPAN:CGI is a core Perl module (i.e. built into all Perl installations), so something weird is happening if your installation can't find it (perhaps you don't have read + execute permissions on the Perl installation dirs mentioned in @INC?).

I think this is more of a Perl installation problem really, as suggested by the error message. Also, you would normally install the CGI.pm file into something like $HOME/dev/perl/lib, allowing other modules to be installed into the same directory tree.

The CPAN:CPAN module has some instructions on how to use the CPAN installer to install modules to directories under your home directory - this is a cleaner way to install things once you know how to configure the installer.

-- RichardDonkin - 05 Dec 2003

Topic revision: r2 - 2003-12-05 - RichardDonkin
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.