From: Dirk on
#!/usr/bin/expect -f

spawn rsync -r --progress a u(a)bla.com:/b
expect "assword:"
send "password\r"
expect "hostname"


why does this script stop while rsync is still transferring?


(hostname is the name of the host in the prompt)


and, yes, it HAS TO BE done using expect... any answer including the word "keys" will not be helpful



Thanks,

Dirk


--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/4C4B94FF.6060802(a)gmx.net
From: Dirk on
Mike Bird wrote:
> On Sat July 24 2010 18:36:47 Dirk wrote:
>> #!/usr/bin/expect -f
>>
>> spawn rsync -r --progress a u(a)bla.com:/b
>> expect "assword:"
>> send "password\r"
>> expect "hostname"
>>
>>
>> why does this script stop while rsync is still transferring?
>>
>>
>> (hostname is the name of the host in the prompt)
>>
>>
>> and, yes, it HAS TO BE done using expect... any answer including the word
>> "keys" will not be helpful
>
> From "man rsync":
>
> Some modules on the remote daemon may require authentication. If so,
> you will receive a password prompt when you connect. You can avoid the
> password prompt by setting the environment variable RSYNC_PASSWORD to
> the password you want to use or using the --password-file option. This
> may be useful when scripting rsync.
>
> WARNING: On some systems environment variables are visible to all
> users. On those systems using --password-file is recommended.
>
> --Mike Bird
>
>

does not work


--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/4C4B9A25.4020206(a)gmx.net
From: Mike Bird on
On Sat July 24 2010 18:57:57 Dirk wrote:
> does not work

Ah yes. I should have noticed that you're probably using ssh.

Try installing sshpass instead of using expect. When rsync sees
expect's sockets it mistakenly thinks it's a daemon.

--Mike Bird



--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/201007241951.28660.mgb-debian(a)yosemite.net
From: Aaron Toponce on
On 07/24/2010 07:35 PM, Dirk wrote:
> #!/usr/bin/expect -f
>
> spawn rsync -r --progress a u(a)bla.com:/b
> expect "assword:"
> send "password\r"
> expect "hostname"
>
> why does this script stop while rsync is still transferring?
>
> (hostname is the name of the host in the prompt)
>
> and, yes, it HAS TO BE done using expect... any answer including the word "keys" will not be helpful

Why?

--
. O . O . O . . O O . . . O .
. . O . O O O . O . O O . . O
O O O . O . . O O O O . O O O