[c-nsp] XRIOS commit tp TFTP

Nemeth Laszlo csirek at cooler.hu
Tue Jun 28 08:06:42 EDT 2016


Thanks for your mail.

May be the best option in this case is an alias, but i didn't find with 
my best friend (Google) any usable info how can i do that.

I would like to do like this:

alias c commit;sh configuration commit list 1|utility XXX ; sh 
configuration commit changes last 1 | file 

So the XXX is a regex that get the commit ID from the "sh configuration 
commit list 1" and i use it in the end of the last command where i send 
the output of last commit to tftp.


2016-06-28 10:19 időpontban James Bensley ezt írta:
> On 27 June 2016 at 12:17, Nemeth Laszlo <csirek at cooler.hu> wrote:
>> Hi
>> We have some ASR9K1 with 4.3.1 OS. We would like to send TFTP every 
>> commit
>> content if somebody make a "commit".
>> I would like to put the Commit ID to the saved filename for the better
>> search.
>> I played with an alias c "commit ; show configuration commit changes 
>> last 1
>> | file tftp:" but in this case no option to put the commit ID to the
>> filename in the TFTP file.
> I few off-the-top-of-my-head ideas that may or may not work;
> 1. You could try and pipe the output from "show configuration commit
> list" to get the commit ID from the last change, using the unix
> utilities and awk/pgre/xargs the commit ID into the TFTP url
> 2. You coul try and run a perl script;
> https://supportforums.cisco.com/discussion/12420571/asr9000-perl-scripting-shell-environment
> 3. Pull fromthe box rather than push
> 4. Upgrade from IOS-XR 4.3.1 before the Sun explodes!
> 5.In XR 6.1 Linux containers are coming and the support for 3rd party
> Linux tools (bash, python etc) so you can run more than "just simple
> Perl scripts" (I don't think many Perl modules are present in IOS-XR
> 4.3.!).
> Cheers,
> James.
> _______________________________________________
> cisco-nsp mailing list  cisco-nsp at puck.nether.net
> https://puck.nether.net/mailman/listinfo/cisco-nsp
> archive at http://puck.nether.net/pipermail/cisco-nsp/

More information about the cisco-nsp mailing list