cmd gets timed out

cmd gets timed out

am 07.08.2006 13:55:08 von Xinx

I am facing a timeout problem. I am logging in to a terminal server
port .This session does not have any prompt , its just blank .I wrote
the follwoing script :...it works fine till "print "WHERE AM I\n";"
and then it gets timed out :-(....i am not sure whats wrong...since
there is no prompt also...setting a prompt on net::telnet is also not
known to me ???Can anybody help.?


sub executeCommand
{
use constant DEBUG => 1;
my $ipaddress = $_[0];
my $portnum = $_[1];
my $command = $_[2];
print "command is $command";
my $objIdentifier = new Net::Telnet (Timeout=> 20, Input_log=>
"debug-telnet.txt") || die;
$objIdentifier->open(Host => $ipaddress,Port => $portnum);
print "objectidentifier = $objIdentifier";
print "Host ip address = $ipaddress\n";
print "Host port number =$portnum\n";
print "WHERE AM I\n";
$objIdentifier->print("\n");
print "i am before snd cmd\n";
}
@output= $objIdentifier->cmd($command);
print "WHERE IS THE OUTPUT DUDE?";
print "OUTPUT of command $command=@output\n";

Regards
Xinx