Peña, Botp
7/5/2005 3:17:00 AM
Wybo Dekker [mailto:wybo@servalys.nl] wrote:
#I'm trying to run a telnet session with my adsl modem with
#
##!/usr/bin/env ruby
#
#require 'net/telnet'
#
#tn = Net::Telnet.new("Host" => "10.0.0.138",
# "Timeout" => 5,
# "Prompt" => /[$%#>] \z/n
#)
#tn.login("wybo", "my_password") { |c| print c }
#tn.cmd("help") { |c| print c }
#tn.close
#
#But it just times out:
#
#$ tn
#/usr/local/lib/ruby/1.8/net/telnet.rb:551:in `waitfor': timed
#out while
#waiting for more data (Timeout::Error)
# from /usr/local/lib/ruby/1.8/net/telnet.rb:719:in `login'
# from ./tn:9
#$
#
#What can be wrong with my script?
can you give us the screenshot if you telnet to 10.0.0.138 manually?
thanks ang kind regards -botp
#
#--
#Wybo
#