![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Calling expect scripts from other expect scripts | seva | Shell Programming and Scripting | 0 | 04-03-2008 10:45 AM |
| tcl/expect | calsum | Shell Programming and Scripting | 7 | 03-25-2008 09:23 PM |
| Expect/Tcl help? | earnstaf | UNIX for Dummies Questions & Answers | 2 | 07-26-2007 07:01 AM |
| Expect and auto expect command | arun_v | Shell Programming and Scripting | 0 | 03-29-2006 04:31 AM |
| Expect with tcl/tk | sanjustudy | Shell Programming and Scripting | 0 | 10-10-2005 02:48 AM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
Help I am trying to do a script
#start expect -F - <<EOF spawn scp -c blowfish -C user@host expect 'word': send 'password\r' while {1}{expect eof{break}} wait eof #end whats wrong with this its not working? and whats a good way to have it copy multiple files? |
| Forum Sponsor | ||
|
|
|
|||
|
I tried this and it works a little crude but
#start File expect -f - <<EOF spawn scp user@host:smtprelay01.latest.sum smtprelay01.txt expect "user@host password:" send "password\r" spawn scp user@host:smtprelay02.latest.sum smtprelay02.txt expect "user@host password:" send "password\r" spawn scp user@host:smtprelay03.latest.sum smtprelay03.txt expect "user@host password:" send "password\r" #while {1} {expect EOF{break}} wait EOF #end |
|
|||
|
The only Problem is the way I wrote the script it logsin...logsout...logsin...logsout...over and over is there any way to string the scp commands together after the expect login?
|
|||
| Google UNIX.COM |