mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
26 lines
475 B
Plaintext
Executable File
26 lines
475 B
Plaintext
Executable File
#!/usr/bin/expect -f
|
|
|
|
# script to log on to a BeBox router [ST Speedtouch 780] and gather line stats
|
|
|
|
# set timeout for response from router to 30 seconds
|
|
set timeout 30
|
|
set router "host.or.ip.of.router"
|
|
set port "23"
|
|
set username "Administrator"
|
|
set password "routerpassword"
|
|
|
|
# telnet to $router on $port
|
|
spawn telnet $router $port
|
|
|
|
expect "Username :"
|
|
send "$username\r"
|
|
|
|
expect "Password :"
|
|
send "$password\r"
|
|
|
|
expect "}=>"
|
|
send "adsl info\r"
|
|
|
|
expect "}=>"
|
|
send "exit\r"
|