| delorie.com/archives/browse.cgi | search |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
| Message-ID: | <20040821194822.91838.qmail@web41212.mail.yahoo.com> |
| Date: | Sat, 21 Aug 2004 12:48:22 -0700 (PDT) |
| From: | Andrew Louder <ajlouder AT yahoo DOT com> |
| Subject: | Problem with cygwin expect calling ssh. |
| To: | cygwin AT cygwin DOT com |
| Cc: | ajlouder AT yahoo DOT com |
| MIME-Version: | 1.0 |
To whom it may concern:
My script works on a older cygwin software:
expect == 5.26
ssh == OpenSSH_3.6.1p2
My script fails on a current cygwin software:
expect == 5.26
ssh == OpenSSH_3.8.1p1
The symptons show that expect can not recognize the
ssh output, so
I will be prompted over and over again for the
password.
Also note, if I ssh from the older installation to the
current
installation,
then my script works again. It appears the problem
lives is term
compatibility.
Andy
PS. Here is my script and example successfull
execution:
$ cat t.exp
#!/usr/local.bin/expect -f
set timeout 60
send_user "Logging into pilot 172.18.64.110\n"
if {[catch {spawn ssh root AT 172 DOT 18 DOT 64 DOT 110}] != 0} {
send_user "PwrSlammer.exp could not telnet to
172.18.64.110\n"
exit -1
}
expect "Are you sure you want to continue connecting*"
{ send "yes\r"
; exp_co
ntinue } \
"password:*" { send "pillar\r" ; exp_continue
} \
"#" { }
Administrator AT coibmtest1 /tmp
$ expect -f t.exp
Logging into pilot 172.18.64.110
spawn ssh root AT 172 DOT 18 DOT 64 DOT 110
root AT 172 DOT 18 DOT 64 DOT 110's password:
Last login: Sat Aug 21 13:19:54 2004 from
coibmtest1.test.pillar
[root AT pilot1 root]#
_______________________________
Do you Yahoo!?
Win 1 of 4,000 free domain names from Yahoo! Enter now.
http://promotions.yahoo.com/goldrush
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |