Please HELP: spawn telnet error in Expect 
Author Message
 Please HELP: spawn telnet error in Expect

Help!
I had written this email a couple of months ago and didn't receive any
response. Any help would be appreciated!

nirav
-------------------------------
Hello,
I am facing a problem with spawn telnet in TCL 8.0 with Expect 5.21 in
Win 2000 environment (666 MHz w/ 256 MB of RAM). I am trying to telnet
to a router 5000 times continuously. For some reason, telnet fails
after 1961 times. Just to make sure that nothing is wrong with the
router, I tried the same test in Sun Solaris Environment. The test
passed in Solaris (it was able to telnet 5000 times). But, it fails
after 1961th telnet every time in Win 2000 environment.
Below is the snapshot of the script. I got "case: Connected" 1961 times
and "case: timed out" for the rest of the times. I don't get any
spawnErrors. expect_out(buffer) is not defined on timeout. And
reproducing this error takes couple of hours since it has to telnet so
many times (any idea on how i can reproduce it faster?). The error only
occurs if i try to telnet more than 1961 times in ONE tcl process. Has
anyone seen this problem before? What could be going on?

Any ideas, alternatives, help will be appreciated.

thanks,
nirav

p.s. the script:

if [catch {spawn telnet 111.11.1.111} spawnError] {
    puts "error: $spawnError"
    close;wait

Quote:
}

sleep 2
expect {
    "connection refused" {
puts "case: connection refused"
close;wait
    }
    "unknown host" {
puts "case: unknown host"
close;wait
    }
    "Connection closed" {
puts "case: Connection closed"
close;wait
    }
    "Connected" {
puts "case: Connected"
break
    }
    timeout {
puts "case: timed out"
puts "expect_out(buffer) is $expect_out(buffer)"
close;wait
    }

Quote:
}

Sent via Deja.com
http://www.*-*-*.com/


Sun, 15 Jun 2003 01:01:22 GMT  
 Please HELP: spawn telnet error in Expect
I'm not sure what you wonna do, but I'm think the problem is not Win 2000...
it's a machine's problem... 1961 telnet sessions opened!!! Do you need more
sessions?

--
___________________________
Asier Burgoa Gonzlez

niac, Sistemas Informticos S.A.
LOGRO?O (La Rioja) SPAIN
+34 941 28 28 28
___________________________



Sun, 15 Jun 2003 02:11:13 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. expect: nesting spawn tftp inside spawned telnet

2. using spawn socket instead of spawn telnet in expect

3. Spawn a telnet session from a spawned telnet session

4. Please help ssh spawn loop problem, expect crashing

5. expect fails to spawn telnet successfully

6. Tcl Expect leaks memory in spawning telnet session

7. Expect/How to determine if a telnet spawn failed

8. Cygnus Expect spawning gnu telnet client on NT

9. Expect: exiting Spawned telnet, ftp

10. Operations on log_file before end-of-expect (spawn telnet)-script

11. Help with Expect error - invalid spawn id

12. expect_after executes for spawn id 1 even if the corresponding expect executes for spawn id 2

 

 
Powered by phpBB® Forum Software