Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^4: How can I connect to a Linux Machine from a Windows Box

by blackadder (Hermit)
on May 03, 2007 at 12:13 UTC ( [id://613362] : note . print w/replies, xml ) Need Help??


in reply to Re^3: How can I connect to a Linux Machine from a Windows Box
in thread How can I connect to a Linux Machine from a Windows Box

HELP!

I have tried this
#! c:/perl/bin/perl.exe use strict; use Net::SSH::Perl; use Net::Telnet; my $ssh = Net::SSH::Perl->new("RVM701"); $ssh->login("root", "password");
And I got this in retun!
F:\SDK\Scripts\D&A>vmlicecheck1.pl The getpwuid function is unimplemented at C:/Perl/site/lib/Net/SSH/Per +l.pm line 110.
Then I tried this
my $host = "RVM701"; my $username = "root"; my $password = "password"; my $thost = new Net::Telnet( Timeout => 20, Host => $host, Errmode => "return" ); $thost->login( $username, $password ); my $prompt = "_MYPROMPT_"; $thost->prompt("/$prompt\$/"); $thost->cmd("set prompt = '$prompt'"); # depends on the shell in +use. my $command = "ls"; my @out = $thost->cmd($command); $thost->close;
And this was the result!
F:\SDK\Scripts\D&A>vmlicecheck1.pl Can't call method "login" on an undefined value at F:\SDK\Scripts\D&A\ +VmLicechec k1.pl line 24.
Please, Can I rely on your legendry kindness and get enlightenment on what’s wrong and how can I rectify this please? Thanks indeed

Cheers

********************* UPDATE *************************

Only SSH service is available on the linux servers! cannot use FTP or Telenet!

Any Clues for me Please?
Blackadder