Web lists-archives.com

Re: Optimizing use of /var/cache/apt/archives/ by Synaptic &/or apt-get

On 01/23/2019 08:53 AM, Pascal Hambourg wrote:
Le 23/01/2019 à 15:43, Richard Owlett a écrit :

1. If /var/cache/apt/archives/ has the same or later version version of a package, will Synaptic and apt-get automatically use contents of /var/cache/apt/archives/ in preference to downloading whatever is at location specified by sources.list?

Same version : yes. Later version : no.

2. If there is no internet connection at the moment, will Synaptic and apt-get  use the latest version in /var/cache/apt/archives/ ?

apt-get uses a version in the cache if and only if it matches the requested version, regardless of the internet connectivity.

1) apt decides which version of a package it wants.
2) If that package version is present in the cache, it uses it.
3) Otherwise, it selects a mirror and downloads it from there.

I may have some re-thinking to do. Due to bandwidth I avoid downloads whenever possible. Instead I purchase DVD sets. That's no real problem for the machine whose purpose resembles a typical user's.

I have a couple of machines set aside for experimentation. The explicitly have no connectivity to the outside world. My mental image resembled using the cache contents as an local pseudo-repository. I may have to create a real one.