lftp icon indicating copy to clipboard operation
lftp copied to clipboard

Mirror sometimes hangs on completion with --loop

Open DuncanSands opened this issue 5 years ago • 5 comments

x86-64 Ubuntu 18.04.4 LFTP | Version 4.8.4 Libraries used: GnuTLS 3.6.5, idn2 2.0.4, Readline 8.0, zlib 1.2.11

.lftprc: debug

Connection method: sftp

Hanging mirror command (doesn't always hang): mirror -v --continue --delete --loop --parallel=2 --use-pget=4 --on-change=!"touch $TOUCHFILE" -p -X metadata* -X .state -X Events* -X FoundationCompanyPlusDaily Products mirror

I noticed that every time it hangs, there is "Retrying mirror" followed by download of an additional file. For example:

Transferring file CurrencyRates/CurrencyRatesChange20200318.zip' ... more files here... PriceEquityRecentHistoryIntraday/PriceEquityRecentHistoryIntradayChange20200318-02.zip' Total: 29 directories, 900 files, 0 symlinks New: 38 files, 0 symlinks 94670 bytes transferred in 101 seconds (939 B/s) Retrying mirror... Transferring file `GICRS_ISIN_Daily/GICRS_ISIN_DailyChange20200318210016-001.zip' ... hangs ...

I am trying without --loop to see if it helps, but it will take a few days to know.

Debug log: lftp.log

DuncanSands avatar Mar 19 '20 08:03 DuncanSands

I can confirm that without --loop there is no hang.

DuncanSands avatar Apr 02 '20 14:04 DuncanSands

i can confirm as well on 20.04.

It hangs with retrying the whole parent process somehow and goes into a infinite loop as this is in my case the bash script. If run manually inside the lftp promt it won't hang.

andrei-radulescu avatar May 19 '21 11:05 andrei-radulescu

I am stuck on Getting directory contents (0) [Waiting for response...] while trying to run reverse mirror with --loop. The files are transferred properly. Running manually inside lftp does not help. At first I thought it might be log files be added to the src directory, but putting them somewhere else does not help.

ProjectMountiainMan avatar Sep 20 '22 17:09 ProjectMountiainMan

Adding the -P flag (-P 5) seemed to fix the hanging behavior for me.

ProjectMountiainMan avatar Sep 20 '22 19:09 ProjectMountiainMan