Ask Your Question
4

dnf - Resume download instead of starting it over

asked 2015-11-06 06:33:33 -0500

Samurai gravatar image

updated 2016-09-12 05:37:58 -0500

I'm normally behind a very slow and unstable internet connection and this has become very frustrating lately. Whenever downloading a package gets interrupted, dnf starts it over from the beginning. yum was smart enough to continue if I'm not mistaken.

What can I do to make dnf continue downloading the rest of the package instead of starting it over?

When downloading set of packages it used to restart the whole thing which I used keepcache=1 from this question and it did the trick, but still have to spend a lot of time to repeat downloading the same package over and over and it gets stuck (default 3 simultaneous downloads) so I have to exclude that package and leave it for another time. It has become even more frustrating now that I'm trying to upgrade to 23, but been having the same problem since dnf was replaced.

EDIT:
It seems whenever a mirror fails and a new mirror is tried, downloading the package starts over.
For example after 60% I get the following message and it starts from 0% again:

Curl error (28): Timeout was reached for *** [Operation too slow. Less than 1000 bytes/sec transferred the last 120 seconds]

Curl error (18): Transferred a partial file for *** [transfer closed with *** bytes remaining to read]
edit retag flag offensive close merge delete

Comments

Your issue has been reported in bugzilla and the resolution is to use keepcache=1 as you did.

It seems not so many options remain. I would test :

  • fastestmirror=1
  • deltarpm=1 (default behavior but check if package is installed)
  • max_parallel_downloads=1
yolo gravatar imageyolo ( 2015-11-06 07:53:12 -0500 )edit

Thanks for the comment. So if I understand correctly there's no way I can achieve what I'm looking for for now?

  • added fastestmirror=1 to dnf.conf. Can't comment about the outcome yet, but it shouldn't have much to do with the main issue.
  • deltarpm is set to 1 and the package is installed
  • I normally play around with max_parallel and set it to higher numbers (e.g. 5) to get past the problematic packages and leave them for the end. With one I'll end up downloading the same package over and over until it succeeds or I get tired!
Samurai gravatar imageSamurai ( 2015-11-07 03:48:51 -0500 )edit

That bug - and similar bugs I checked, are mostly about not downloading already downloaded packages rather than not starting over downloading the same package. I see at times that dnf says something along "downloading cancelled after reading xxxxx bytes" maybe failing a mirror and trying a new one resets that?

Samurai gravatar imageSamurai ( 2015-11-07 03:54:25 -0500 )edit

So if I understand correctly there's no way I can achieve what I'm looking for for now? => maybe someone else will have other clues.

Due to your slow internet connection, I would set max_parallel_downloads to 1, that means you download only one package at a time in using the whole bandwidth and until the connection becomes unstable.

yolo gravatar imageyolo ( 2015-11-07 08:57:30 -0500 )edit

There's no feature for resuming the partial download of a single package. You should expect a partial download of a set of packages to keep the packages that have completely downloaded; if not, that's a bug and you should update dnf by itself first. A slow download speed from all available mirrors is most likely due to your own network connection and not a bug.

randomuser gravatar imagerandomuser ( 2015-11-18 08:02:32 -0500 )edit

3 Answers

Sort by ยป oldest newest most voted
0

answered 2018-05-12 09:17:18 -0500

lsatenstein gravatar image

May 2018 When dnf gets interrupted and I restart it, I see many "skip messages" for files that have already been downloaded. Is your problem still persisting?

I do have a faster internet service and that might prevent my system from seeing your issue.

edit flag offensive delete link more

Comments

The question is about huge packages that are interrupted.

abitrolly gravatar imageabitrolly ( 2018-05-12 10:58:09 -0500 )edit

As abitrolly said the question is about resuming to download packages that are partially downloaded. If some packages are fully downloaded, then it skips them next time. Since I changed my internet provider this hasn't been much of a problem, though still loved yum's resume plugin,

Samurai gravatar imageSamurai ( 2018-05-12 18:22:47 -0500 )edit
0

answered 2018-05-12 06:19:36 -0500

abitrolly gravatar image

Although Fedora seemed to provide Metalink files for downloads, I can not confirm that there is:

  1. support for Metalink for updates
  2. links for segmented downloads
  3. support for segmented downloads in dnf

Until there is a way to verify and check this, I found the comments to question useful to limit download stream over my 100kb/s mobile connection with max_parallel_downloads=1 option.

dnf update  --setopt max_parallel_downloads=1
edit flag offensive delete link more
0

answered 2019-01-28 11:09:53 -0500

I always prefer to use dnf to restart the download. Usually, if I start the download from the place where it stopped, the file gets damaged and then there may be problems when opening it. And problems with the downloading can occur even when downloading small files. I ordered a resume from topresume.com and when they sent me the final version, I started having big problems downloading it. But I was lucky these guys quickly responded when I reported the problem and were able to quickly send me the files again.

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2015-11-06 06:33:33 -0500

Seen: 1,488 times

Last updated: May 12 '18