Thanks I triedmy $s = Net::Appliance::Session->new({ personality => 'ios', transport => 'SSH', Input_log => 'input.log', Timeout => 15, host => $ip, });
I got#!/usr/bin/perl use Net::Appliance::Session; my $s = Net::Appliance::Session->new({ personality => 'ios', transport => 'SSH', host => $HOST, privileged_paging => 1, # only if using ASA/PIX OS 7+ # and there are other behaviour options, +see below }); try { $s->connect({ username => 'XXXXX', password => 'XXXXXXX' }); $s->begin_privileged; print $s->cmd('show ver'); $s->end_privileged; } catch { warn "failed to execute command: $_"; } finally { $s->close; };
$ perl getasrrun.pl failed to execute command: read timed-out at /usr/local/share/perl/5.1 +4.2/Net/CLI/Interact/Transport/Wrapper/Net_Telnet.pm line 35 Execution of finally() block CODE(0xa17c388) resulted in an exception, + which *CAN NOT BE PROPAGATED* due to fundamental limitations of Perl +. Your program will continue as if this event never took place. Origi +nal exception text follows: read timed-out at /usr/local/share/perl/5.14.2/Net/CLI/Interact/Transp +ort/Wrapper/Net_Telnet.pm line 35
In reply to net::applance::session Help by viperbmw69
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |