[rancid] Re: Cisco commands containing ';'...

Ryan West rwest at zyedge.com
Wed Sep 16 17:37:35 UTC 2009


Have you tried an escape "\" ?

Not sure it would help, but worth a try.

-ryan

-----Original Message-----
From: rancid-discuss-bounces at shrubbery.net [mailto:rancid-discuss-bounces at shrubbery.net] On Behalf Of Jon Peatfield
Sent: Wednesday, September 16, 2009 1:02 PM
To: rancid-discuss at shrubbery.net
Subject: [rancid] Cisco commands containing ';'...

I may have been expecting too much but I wanted to run:

  clogin -c 'conf t; boot system flash:bootimage1;flash:bootimage2; exit' a b c

to set the boot path on a set of identical switches.  Of course clogin 
splits the command at the ; in the middle of the boot system command so 
that fails...

So I thought I need to use -x and pass a file with the lines but that also 
fails because it seems that clogin actually joins the lines from the file 
with ; and then treats is just as if it was a -c option (ie it splits it 
at all ; again).

So is there a way to bypass the split and get a real ; into a command?

A glance through the code doesn't suggest anything obvious but I may be 
missing a trick...

-- 
/--------------------------------------------------------------------\
| "Computers are different from telephones.  Computers do not ring." |
|       -- A. Tanenbaum, "Computer Networks", p. 32                  |
---------------------------------------------------------------------|
| Jon Peatfield, _Computer_ Officer, DAMTP,  University of Cambridge |
| Mail:  jp107 at damtp.cam.ac.uk     Web:  http://www.damtp.cam.ac.uk/ |
\--------------------------------------------------------------------/
_______________________________________________
Rancid-discuss mailing list
Rancid-discuss at shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss


More information about the Rancid-discuss mailing list