AptProxyCache

Summary

Including an Apt proxy cache in the main repository and documenting its installation and configuration would reduce time and bandwidth usage when deploying, updating or installing packages for Ubuntu machines on the same network.

Release Note

Ubuntu Server ships an apt proxy cache, altough not active by default. It allows to reduce bandwidth and time when installing or updating Ubuntu machines on a network.

Rationale

Downloading the same packages and updates over the Internet for every Ubuntu machine on a network is a waste of bandwidth and time. Choosing an available apt proxy cache from universe, including it in main and documenting its installation and configuration on Ubuntu Server would solve this issue.

Use Cases

  • Alan admins a network of several Ubuntu machines and wants the packages and updates to be downloaded only once and fetched by all the machines.
  • Betty deploys a lot of Ubuntu machines daily and she wants the unattended installations to fetch the packages and updates directly from an Ubuntu Server on her network.
  • Chuck has several Ubuntu machines at home and doesn't want to use his limited bandwidth to download the packages updates for each one of his machines.

Design

Option 1: using apt-cacher-ng

Info:

Pros:

  • Can import already available package files into the cache.
  • Web frontend to see statistic reports and trigger different actions.

Cons:

  • Configuration on the client side is needed (modification of mirror access URLs or APT's HTTP proxy setting)

Option 2: using apt-cacher

Info:

  • package version in Jaunty: 1.6.7
  • Website:
  • Last release: 1.6.7
  • License: GPL

Pros:

  • Can import already available package files into the cache.

Cons:

  • Configuration on the client side is needed (modification of mirror access URLs or APT's HTTP proxy setting)

Option 3: using apt-proxy

Info:

Pros:

  • Can import already available package files into the cache.

Cons:

  • Configuration on the client side is needed (modification of mirror access URLs or APT's HTTP proxy setting)

Option 4: using approx

Info:

Pros:

  • Allows to change repositories in the server transparently to the clients.

Cons:

  • Configuration on the client side is needed (modification of mirror access URLs or APT's HTTP proxy setting)

Goals

  • Choose an apt proxy cache from universe and include it in main.
  • Include how to configure it in the Ubuntu Server Guide.

Implementation

Targets

Jaunty+1

All goals should be achieved by this release.

Test/Demo Plan

  • Once the chosen package is in main, test it in real network environments with several Ubuntu machines.
  • Try to use it in an unattended installation.

BoF agenda and discussion

Experience with Apt-cacher

The following comments comes from my experience using apt-cacher. They may apply to the other package caching proposals:

  • Conflict with Debian packages - Ubuntu rebuilds but does not rename some packages. This causes problems with apt-cacher where the first system (debian, ubuntu) to fetch thae package has it retained in the cache, which causes problems with the other system. Solution(s): Have Ubuntu rename every package that it builds / Don't allow debian systems access the cache
    • [FIXED] by adding namespace support to apt-cacher
  • Configuration of clients - A URL prefix needs to be added to sources.list URLs locally to each machine. Solution(1): Modify apt to allow a debconf parameter (sourceprefix?) to be added as a prefix to all URLs used. Solution(2): Modify apt-cacher to allow it to be used as a http proxy and use the http proxy option to apt to redirect request to the ubuntu server. (The proxy option in apt is a debconf variable.)
    • [FIXED] by modifying apt-cacher to be used as a http proxy


CategorySpec

AptProxyCache (last edited 2015-07-12 18:03:15 by d0017-2-88-172-31-68)