or the original title name, today in the intranet Ubuntu system to update the scheme, see the site on a post, is very excited. Can take a look but found that this apt-proxy is not in the Ubuntu 12.04 (LTS) release version, it seems that this post is a bit not keep up with the kind of trend. Check the data, the current release version provides the approx. The official description is as follows:
Approx is a http-based proxy server for Debian-style package archives. It fetches files from remote repositories in demand, and caches them for local use.
Approx saves time and network bandwidth if your need to install or upgrade. Deb packages for a number of machines on a loca L Network. Each package are downloaded from remote site only once, regardless the how to many local clients install it. The approx cache typically requires a few gigabytes of disk space.
Approx also simplifies administration of client machines:repository locations need only is changed in approx ' s config Uration file, not in every client ' s/etc/apt/sources.list file.
Approx can is used as a replacement for apt-proxy, with no need to modify clients '/etc/apt/sources.list files, or as a Lternative to Apt-cacher.
Approx seems to have replaced Apt-proxy, which no longer offers apt-proxy after 10.04.
Approx deployment is also extremely simple, first deploy approx:
sudo apt-get install approx
Get the update address in the current/etc/apt/sources.list by the command below
$ GREP-E "^[^#]" sources.list | Cut-d ""-f2 | Uniq
http://au.archive.ubuntu.com/ubuntu/
Http://security.ubuntu.com/ubuntu
Configure the/etc/approx/approx.conf file and add the following
Ubuntu Http://cn.archive.ubuntu.com/ubuntu
Ubuntu-extras Http://extras.ubuntu.com/ubuntu
Ubuntu-partner Http://archive.canonical.com/ubuntu
Ubuntu-security Http://security.ubuntu.com/ubuntu
$ sudo/etc/init.d/openbsd-inetd Restart
* Restarting Internet superserver inetd [OK]
After restarting, the service is already running on port 9999.
In the client configuration, is actually the client's/etc/apt/sources.list file changes to your approx address on it:
Deb Http://approx:9999/ubuntu/precise main restricted
DEB-SRC http://approx:9999/ubuntu/precise Main restricted
Deb Http://approx:9999/ubuntu/precise-updates main restricted
DEB-SRC http://approx:9999/ubuntu/precise-updates Main restricted
Deb Http://approx:9999/ubuntu/precise Universe
DEB-SRC Http://approx:9999/ubuntu/precise Universe
Deb Http://approx:9999/ubuntu/precise-updates Universe
DEB-SRC Http://approx:9999/ubuntu/precise-updates Universe
Deb Http://approx:9999/ubuntu/precise Multiverse
DEB-SRC Http://approx:9999/ubuntu/precise Multiverse
Deb Http://approx:9999/ubuntu/precise-updates Multiverse
DEB-SRC Http://approx:9999/ubuntu/precise-updates Multiverse
Deb Http://approx:9999/ubuntu/precise-backports main restricted universe multiverse
DEB-SRC http://approx:9999/ubuntu/precise-backports main restricted universe multiverse
Deb Http://approx:9999/ubuntu precise-security main restricted
DEB-SRC Http://approx:9999/ubuntu precise-security Main restricted
Deb Http://approx:9999/ubuntu precise-security Universe
DEB-SRC Http://approx:9999/ubuntu precise-security Universe
Deb Http://approx:9999/ubuntu precise-security Multiverse
DEB-SRC Http://approx:9999/ubuntu precise-security Multiverse
The other addresses can be deleted. The rest is sudo apt-get update ~ ~ ~