LFTP Reconnect infinite loop

meso_2600 picture meso_2600 · Jul 15, 2014 · Viewed 8.5k times · Source

When I try to connect to the host that is dwon I get the following message:

cd `sftp://example.com/tmp' [Delaying before reconnect: 30]

After each attempt delay sis increasing. I found the following command that should help me:

repeat -d 10  -c 1 

which should delay by only 10 seconds (instead of default 30) and repeat th ecommand only once.

But still I get Delaying reconnect in endless loop.

Answer

meso_2600 picture meso_2600 · Jul 15, 2014

ok found it:

lftp -e "set net:max-retries 2;set net:reconnect-interval-base 5;set net:reconnect-interval-multiplier 1 ;mirror  -v --just-print '/tmp/md1/' '/tmp/m2'" sftp://example.com