Re: Help, using script to edit router config (entering different modes automatically)
- From: oldoak@xxxxxxxxx ("zackrspv")
- Date: Wed, 24 Jan 2007 20:54:50 -0800
On Oct 27 2006, 1:32 am, bjorge.so...@xxxxxxxx (Bjorge Solli) wrote:
On Friday 27 October 2006 09:23, Michael Alipio wrote:
Hi,
Suppose I have an appliance, it's not cisco but the process of updating
configuration is almost the same.
1. First you log-in either viasshor telnet..
2. Then you go into a certain mode by typing a particular command.
3. Only after you have enter that mode, you can issue the actual editing
command, (e.g; set ip 192.168.1.1) 4. Finally, issue another command to
apply the configuration change.
I need to execute these steps on a regular basis via cron.
Step 1 is not a problem I guess because I have discovered that the
appliance supportssshpublic/private key authentication. Step 2 is also
not a problem since I can execute it together with the command I use in
step 1,
sshappliance.our.domain "conf t"
Now, what? I don't know what to do next. Any idea?Tried Net::SSH::Perl?http://search.cpan.org/~dbrobins/Net-SSH-Perl-1.30/lib/Net/SSH/Perl.pm
You can sendmultiplecommands separately with that.
I must have missed something, because i'm new, or an idiot, whichever
you choose. But i was under the impression that Net::SSH does not do
multiple commands for 1 connection, only multiple commands for multiple
connections. Net::SSH2 would do multiple commands, but your device has
to support SSH2. Net::SSH::Perl can handle both SSH1 and SSH2, however
it only supports multiple commands if your proto is SSH2.
Are you saying that it IS possible to do multiple SSH commands on ONE
connection using SSH1 via Net::SSH::Perl? Because, if so, please, oh
please, tell me how you managed that?
Thanks!
.
- Follow-Ups:
- RE: Help, using script to edit router config (entering different modes automatically)
- From: Michael Gargiullo
- RE: Help, using script to edit router config (entering different modes automatically)
- Prev by Date: Re: perl and network connection
- Next by Date: Re: trouble with list context assignment for substitution inside File::Find &wanted function
- Previous by thread: SSH
- Next by thread: RE: Help, using script to edit router config (entering different modes automatically)
- Index(es):
Relevant Pages
|