Hello Jack,

On Fri, 31 Aug 2012 17:00:12 +0700
Jack Vo <jacksvo2...@gmail.com> wrote:

> Hello List,
> 
> I'm trying to execute a script which retrieves swap usage memory in 
> remote host. So that I install Net::SSH::Perl module (from source
> code) from CPAN website.
> My script below :
> > #!/usr/bin/perl -w
> > use strict;
> > use Net::SSH::Perl;
> >
> > my $hostname = "192.168.7.5";
> > my $username = "abcd";
> > my $password = "abcd";
> >
> > my $cmd = "free -m";
> >
> > my $ssh = Net::SSH::Perl->new("$hostname", debug=>0);
> > $ssh->login("$username","$password");
> > my ($stdout,$stderr,$exit) = $ssh->cmd("$cmd");
> But the output has some error message and don't know how to solve
> this problem.
> > Can't locate Math/Pari.pm in @INC (@INC contains: 
> > /usr/lib/perl5/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/5.8.8 
> > /usr/lib/perl5/site_perl/5.8.8/x86_64-linux-thread-multi 
> > /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl 
> > /usr/lib/perl5/vendor_perl/5.8.8/x86_64-linux-thread-multi 
> > /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl .) at 
> > /usr/lib/perl5/site_perl/5.8.8/Net/SSH/Perl/Util/SSH2MP.pm line 6, 
> > <GEN0> line 1.

This means you need to install the Math::Pari module from CPAN or from your
distribution's package repository. On rpm-based systems installing 
perl-Math-Pari
should work.

Regards,

        Shlomi Fish

-- 
-----------------------------------------------------------------
Shlomi Fish       http://www.shlomifish.org/
Parody of "The Fountainhead" - http://shlom.in/towtf

Confucius says: “XSLT made me realise humanity was hopeless.”.

Please reply to list if it's a mailing list post - http://shlom.in/reply .

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to