Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^4: Perl Script to enable Cisco

by Null_Route0 (Initiate)
on Jul 23, 2012 at 18:05 UTC ( #983216=note: print w/ replies, xml ) Need Help??


in reply to Re^3: Perl Script to enable Cisco
in thread Perl Script to enable Cisco

Heres the outout I get when I run the script, I tried adding the say but it produced the same results.

Layer-2 Switch Line has invalid autocommand "show running-config"

In order for me to execute the show run config I need to get the box into enabled mode. I copied the sequences below from the CLI of me running the commands manually. Hopefully it will help illustrate what I am trying to do.

Switch-01>enable <--- Log on to box and type enable

Password: <---prompts for password

Switch-01#sho run <--- drops into privilege mode where I can run the show run command

Building configuration...

also I was able to get rid of the newline character by adding

chomp ($filename);


Comment on Re^4: Perl Script to enable Cisco
Re^5: Perl Script to enable Cisco
by aitap (Deacon) on Jul 23, 2012 at 18:12 UTC
    Please, use our HTML-like markup on your posts, especially <code>...</code> tag. Note that you can edit your messages anytime.
    Sorry if my advice was wrong.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://983216]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (7)
As of 2014-12-27 23:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (177 votes), past polls