I have a LAN where I currently use an instance of Sonatype Nexus to proxy several yum repositories. All the clients on the LAN are configured to install packages only from this service.
The only reason why Sonatype Nexus is used is because the configuration provider already existed at the time. It is not a mirror, since it caches each package on demand. This is the desired effect, as I don't want to store every package in all the yum repositories being proxied.
So far so good. What I would like now is to add a secondary cache, in case the first goes down or maybe is slow:
Mirror1 Mirror2 ...MirrorN
\ \ / \ /
+----\--------+----\-------------+
| \ \ /
| +-------------+---------+
| |
+--------------------------+ +--------------------------+
| CacheA | <==Sync==> | CacheB |
| Repo1, Repo2, ..., RepoN | | Repo1, Repo2, ..., RepoN |
+--------------------------+ +--------------------------+
| |
| +--------------+--+---+
| / / \
+---/--------+-----/----------\--+
/ / \ / \ \
ClientX ClientY ClientZ
I don't have to use Sonatype Nexus. I have heard about pulp, mrepo, and spacewalk and I don't mind getting into one of them if it has better out-of-the-box functionality for what I need.
How can I setup those two caches so they will eventually be synced, without mirroring every proxied repo? The end result is I would like to backup only one of them and have every package that was installed by a client.