Re: download strategy, was Re: apt, yum, up2date, smartpm, ... ?
Les Mikesell <[email protected]>
| Newsgroups | gmane.linux.freshrpms.user |
|---|---|
| Message-ID | <[email protected]> |
On Wed, 2005-09-21 at 17:19, William Stearns wrote:
> > Does it know to only download the packages you need or are you
> > trading being proxy-cache-unfriendly for making copies of
> > stuff you won't ever need.
>
> For the repositories and distributions you request it defaults
> to getting all of their files. That said, you can:
>
> - place any files you already have in the tree in advance so they're not
> downloaded again
Is there an automated way to do this for the base distribution or
pretend you've done it by loopback mounting the distribution
iso images?
> If it's simply a matter of wanting to avoid duplicate downloads,
> it would seem that using proxy such as squid would avoid duplicate
> downloads from a given internet server; the "proxy" option in the "[main]"
> section of /etc/yum.conf would allow you to specify the location of the
> squid proxy to use (man yum.conf).
This doesn't work for repositories that use the mirrorlist option. Yum
picks something different from the list every time, cluttering the
cache and defeating its purpose.
> Here's an open question. If we're not getting all packages in
> advance like yum-pull, but we want to minimize the bandwidth used, is
> there an approach better than "let squid cache requests so the second
> workstation doesn't have to download the file again"? A couple of people
> have used phrases like your "only download the packages you need", and I'd
> be sincerely interested to hear about ways to do that are friendly to
> modem-based users. Is there a third option that's an alternative to "get
> all files in advance" and "wait for the files to come down after the user
> requests a package install or upgrade"?
> Would "download only new versions of packages I currently have
> installed" be the third option you want? That would speed up patches, but
> wouldn't help with installing new software and might run into problems if
> a patch rpm requires libraries you don't currently have installed.
No, it would need to work like a proxy cache combined with
yum --download-only ... &
so yum could decide what it needs and get it in the background or
as a scheduled command - and this needs to report it's status so
you know whether or not everything is available for the subsequent
real yum action.
There is another reason for wanting to download a local copy of a
repository, though. If you want to update one machine, then do
some testing, then update some others to match what you tested
there is no way to tell yum not to take newer packages that have
become available in the repositories to make the updates repeatable.
Will yum-pull handle that scenario?
--
Les Mikesell
[email protected]