From: t-mitsui@mbj.nifty.com (tak)
Subject: tcl exect stop <tru64:V5.1A>
Date: 6 Sep 2002 07:35:17 -0700 [thread overview]
Message-ID: <1baa7952.0209060635.8f9cba0@posting.google.com> (raw)
I use tru64(V5.1A) UNIX
I made expect(5.31) script like below
tcl version is 8.3
#!/usr/local/bin/expect
set PROMPT $
spawn telnet PS1
#-----------------------------------------
expect "login:"
send "abcde\r"
#-----------------------------------------
expect -ex "Password:"
send "password\r"
#-----------------------------------------
expect $PROMPT
for {set cnt 0} {$cnt < 10} {incr cnt} {
send "ls -a abcde\r"
expect {
"No such file or directory" {
expect $PROMPT
continue
}
$PROMPT {
break
}
timeout {
puts TIMEOUT
continue
}
}
}
#-----------------------------------------
send exit\r
#-----------------------------------------
Actually file abcde is not exist.(this is test script)
About halfway,send command don't work.
So expect script repeat timeout and end.(sometimes freeze)
I take debugging, send "ls -a abcde\r" don't reach remote host.
So expect is timeout.
Please give me something to resolve this problem.
reply other threads:[~2002-09-06 14:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox