You are here:

Perl & CGI/Remote access in Perl


QUESTION: I need to execute some commands in remote linux machine and for that Perl says that i should use some module like Net::SSH. Am a beginner in perl sripting and could u pls help me how and where to save the module after downloading. urgent requirement!!!

ANSWER: Shanthi,

There are two methods you can use to install the Net::SSH module, CPAN, or via manual install.

To use CPAN type:

perl -MCPAN -e ‘install Net::SSH::Perl’

To perform a manual install, download the module from the CPAN website from this link:

Unpack it, then execute the commands to build and install the module:

perl Makefile.PL
make test
make install

My recommendation is to use the first method since the CPAN module should install any prerequisite modules required by Net::SSH

Let me know how this works for you,


---------- FOLLOW-UP ----------

QUESTION: Hi thanks for the reply...
I tried with your suggestion and I got an error as mentined below.

cpan> perl -MCPAN -e `install Net::SSH::Perl'
Text::Parsewords could not parse the line [perl -MCPAN -e `install Net::SSH::Per
l'] at C:/Perl64/lib/ line 369, <IN> line 1.

Could you pls help me out with the solution.
Awaiting reply.....


Try the following steps:

1. Execute the CPAN interactive shell

perl -MCPAN -e shell

Note: you may be prompted for some information if you have never run CPAN before. Answer the questions the best you are able. For the most part the defaults provided will suffice.

2. From within the CPAN interactive shell

install Net:SSH::Perl

This last command will attempt to install the Net::SSH::Perl module (along with any prerequisite modules) on your system.


Perl & CGI

All Answers

Answers by Expert:

Ask Experts


Lukas Neuburger


I can answer a wide range of Perl questions, everything from basic language syntax to popular CPAN modules, to web/CGI scripting and much, much more.


As an experienced technical professional, I leverage the power and flexibility of Perl to develop solutions in a variety of areas, including: web development, database management, and systems administration to name only a few.

Bachelors of Science in Computer Science

©2017 All rights reserved.