Jon Peatfield
2009-09-16 17:01:54 UTC
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...
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: ***@damtp.cam.ac.uk Web: http://www.damtp.cam.ac.uk/ |
\--------------------------------------------------------------------/
/--------------------------------------------------------------------\
| "Computers are different from telephones. Computers do not ring." |
| -- A. Tanenbaum, "Computer Networks", p. 32 |
---------------------------------------------------------------------|
| Jon Peatfield, _Computer_ Officer, DAMTP, University of Cambridge |
| Mail: ***@damtp.cam.ac.uk Web: http://www.damtp.cam.ac.uk/ |
\--------------------------------------------------------------------/