From: Andreas Hoeschler (ahoesch@smartsoft.de)
Date: Fri Apr 12 2002 - 18:13:02 EDT
Thanks a lot to all who responded to my request. I got 50 or so replies.
Most recommended to use expect. I downloaded and compiled expect and
then wrote the following script which did what I want.
#!/usr/local/bin/expect
log_file -noappend "telnetoutput.txt"
spawn telnet 192.168.1.254
expect "assword: "
send "12345\r"
expect ">"
send "ip route status\r"
expect ">"
send "exit\r"
Special thanks to Mike Bruno who provided the script.
Regards,
Andreas
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:24:12 EDT