|
I use to login on a cisco ras 7200 using the module and can execute one single command. But when I try to use more than one command, I get the time out error after the first command. This is the abstract of the script file
$session->dump_log();
$session->input_log();
@output = $session->cmd('show caller summary');
$session->waitfor("/#/");
@output = $session->cmd('show env all');
$session->waitfor("/#/");
@output = $session->cmd('show version');
$session->waitfor("/#/");
@output = $session->cmd('show caller ip');
$session->waitfor("/#/");
@output = $session->cmd('show proc cpu');
$session->waitfor("/--More--/");
$session->print("q");
return $session;
$session->close;
As soon as the first command, in this case 'sh caller summary', gets executed scripts comes out stating time-out error for the line in which first command is written. Though log file shows the command has been executed and the system is back at the prompt .. as show below (input.log file):
Hostname>enable
Password
hostname#show caller summary
64 Analog calls
13 ISDN calls
0 VPDN calls
74 Total unique users logged in
136123 Total users since last reload
hostname#
Any help in this regard is appreciated. Thanking you in advance.
Regards
Yadwendra
|