From: Richard Gallagher (rgallagh@cisco.com)
Date: Tue Feb 24 2004 - 11:15:05 GMT-3
If you have 12.3(1) or later there is a nice new feature in IOS to do
this: Command Scheduler:
HTH, Rich
On Tue, 2004-02-24 at 15:02, Scott, Tyson C wrote:
> Get the O'Reilly Expect book it if very good
>
> I would personally recommend expect. It is much simpler and is more
> powerful in what it can do if you know how to use it. This is a short
> example below. It doesn't take as much code to write a script with
> Expect is what I like but there is not as much written out there about
> it. The website is at http://expect.nist.gov
>
>
> #!/usr/bin/expect
>
> source you use the source command if you are calling from another file
> that is hosting something like your passwords.
>
> You could start a script x command before this so it is logging it to a
> file and autogen this if you would like.
>
> #set pass "your password"
> set timeout 5
> set host $argv
>
> spawn telnet $host
> expect "sword:" { send "vtypass\r" }
> expect ">" { send "enable\r" }
> expect "sword:" { send "enablepass\r" }
> #expect "#" { send "show ip int brief\r" }
> expect "#" { send "exit\r" }
>
> Sorry I don't have time right now to write the script for you but.
> "Give a man a fish you give him a meal for the day. Teach a man to fish
> and you teach him to eat for a lifetime.
>
>
> -----Original Message-----
> From: nobody@groupstudy.com [mailto:nobody@groupstudy.com] On Behalf Of
> Peasah, Richard Kwame
> Sent: Saturday, February 21, 2004 4:27 PM
> To: ccielab@groupstudy.com
> Subject: Anyone doing this?
>
> Gang,
>
>
>
> I want to send the output of this command "sh ip nbar
> protocol-discovery" periodically (like every 30 minutes) from specific
> interfaces to a fileserver for later analysis. Is anyone out there doing
> this or knows how to do this? Cheers.
>
> _______________________________________________________________________
> Please help support GroupStudy by purchasing your study materials from:
> http://shop.groupstudy.com
>
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
>
> _______________________________________________________________________
> Please help support GroupStudy by purchasing your study materials from:
> http://shop.groupstudy.com
>
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html
This archive was generated by hypermail 2.1.4 : Fri Mar 05 2004 - 07:13:56 GMT-3