Why can downloads not be paused?

When using Steam, I can pause downloads. This is especially useful when I need to stream a video or want to play a game part-way through a download. I cannot when using Discover (although PackageKit’s DNF5 backend does cache specific packages). Considering that I don’t see a way to with PackageKit or DNF5, I presume that this is their deficiency. However, I’d like confirmation.

That would be my guess as well.
Either one or more backends don’t support it and having inconsistency might be even less useful.

However, this could also be something that changes over time.
I.e. initially backends might not have been able to do that but could have gained that capability since then. In which case the frontend could be modified to support it as well.

2 Likes

@krake, it’s not something I can confirm via the terminal, for apt, zypper and dnf5 utilise very basic CLIs, which appear to solely accept ^C (rather than, perhaps, a TUI, where one might expect pause capabilities to be exposed).

They might accept a pause via whatever they expose via their C++ or Python bindings, but I don’t have the time to check. Perhaps, large packages aren’t common. That doesn’t apply to Flatpak (and Snap), though, so I’ve asked at reddit.com/r/flatpak/comments/1neoirv.

I’d suggest that it makes sense for Steam, because it is dealing primarily with huge single files, whilst package management is more critical. Resumable downloads aren’t trivial to implement robustly and I think it’s unreasonable to suggest that you must be able to pause essential updates so that you can watch a video.

Packagekit must deal with many small packages so I think it’s more of a ‘design choice’ than deficiency.

Basically, I’d suggest you shouldn’t update/upgrade when you’re too busy.

What could be a nice idea is if there were a way to limit the process to 80% of your bandwidth (as you can with a torrent client, for example).

1 Like

Right, I would not expect them to support pause/resume. Such tools could theoretically support abort/restart though.

Yes, that is what I had in mind. Some of these systems have multiple frontends with different capabilities so their shared internals could very well be capable of resuming partial downloads in one way or another.

This is certainly true for traditional packages because of their fine granularity.
However third party packages like Google’s Chrome are pretty large.

Not to forget images of the immutable distros.

It is an abstraction on top of the distribution specific systems and those might not have had the capability back then. However, some of them (or even all) could have gained such a feature since then and the abstraction could then offer it as well.

Good general advice, however some systems now offer the option to download things in the background and only apply either at request or at restart.

On the other hand mobile platforms do that all the time without much user complaint (if any).

Even that would require backend support unless the backends have the ability to “delegate” downloads back to the frontend.

2 Likes

@ben2talk, why? I had GDPR training to get done within a deadline:

…which occasionally consisted of videos. However, I also needed to download an update to fix the internet connection problems exhibited by the recent kernel updates in order to upload some work, before my brother came home from college:

Those are reasonable priorities that I must juggle. Whilst viewing non-videographic content, I can prioritise the download, whereas I must prioritise bandwidth when watching a video.

I believe that that’s already configurable in most package managers’ configuration files. Having that exposed in Discover might be nice, but worth another thread.


@krake, considering I can cancel a download in dnf5 with ^C, and have it begin downloading the first uncached package when I reinvoke the command, that appears to be available?

Indeed! That was my original reason for asking this, since 0ad and some massive flatpaks updated alongside the kernel:

  1. #!/usr/bin/env sh
    rpm -qa --queryformat '%10{size} - %-25{name} \t %{version} \t %{os} \n' | sort -rh | head -25 | awk '{print $1/1024/1024, $2, $3, $4}'
    
  2. 3353.18 - 0ad-data 0.27.1
    1550.23 - qt6-qtwebengine-debuginfo 6.9.1
    

That’s in MiB (so 0ad-data is 3 GiB).