Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can perl do this? 2

Status
Not open for further replies.
Jul 31, 2001
37
US
I have 32 routers in my company and i need to make sure i have current configs. Can a perl script do something similar to the following
Telnet to a host
type a &quot;password&quot; <cr>
type &quot;enable&quot; <cr>
type a &quot;password <cr>
type &quot;wr&quot; <cr>
type &quot;copy start tftp:&quot; <cr>
type an &quot;ip address&quot; <cr>
type &quot;$var-confg&quot; <cr> (where $var is the name of the router)
type &quot;exit&quot;

I would appreciate any suggestions. Please go easy i'm new to perl and decided to learn it for this task. Thanks in advance.
 
Try the perl module Expect. The syntax is similar to the language &quot;expect&quot;.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top