apt-cacher breaks ltsp-build-client
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
LTSP5 |
Invalid
|
Undecided
|
Unassigned |
Bug Description
To speed up installs and upgrades where internet link is slow, installing apt-cacher-ng on a LAN can make a huge difference. Unfortunately, when you configure LTSP server (Edubuntu 14.04.4 amd64 in my case) to make use of apt-cacher-ng as folllows:
/etc/apt/
Acquire:
Acquire:
Acquire::ftp::proxy "ftp://aptproxy:
Acquire:
/etc/hosts contains an entry for aptproxy:
192.168.0.100 aptproxy
apt-get works like a charm (update, upgrade, dist-upgrade), but ltsp-build-client fails (not finding aptproxy). I am assuming that it does a chroot to client folder and then tries to do apt-get update / upgrade. What is odd is that the client folder does not contain /etc/apt/
Changed in ltsp: | |
status: | New → Invalid |
On 2016-02-23, John Bester wrote: apt.conf. d/80apt- cacher contains the following: :http:: proxy "http:// aptproxy: 3142/"; apt.conf. d/80-apt- cacher, so I would expect it to simply work.
> To speed up installs and upgrades where internet link is slow,
> installing apt-cacher-ng on a LAN can make a huge difference.
> Unfortunately, when you configure LTSP server (Edubuntu 14.04.4 amd64 in
> my case) to make use of apt-cacher-ng as folllows:
>
> /etc/apt/
> Acquire:
...
> /etc/hosts contains an entry for aptproxy:
> 192.168.0.100 aptproxy
>
> apt-get works like a charm (update, upgrade, dist-upgrade), but ltsp-
> build-client fails (not finding aptproxy). I am assuming that it does a
> chroot to client folder and then tries to do apt-get update / upgrade.
> What is odd is that the client folder does not contain
> /etc/apt/
> Appending /etc/hosts (except for 127... addresses) might work as well.
It's probably caching the http proxy in the chroot's apt.conf. d/00proxy- guess, but not copying the /etc/hosts file ltsp/plugins/ Ubuntu/ 010-http- proxy.
/etc/apt/
into the chroot. See /usr/share/
The simple workaround is to use an ip address for the proxy in apt.conf. d/80apt- cacher instead:
/etc/apt/
Acquire: :http:: proxy "http:// 192.168. 0.100:3142/";
You could also use the --http-proxy commandline option to specify the
proxy via ip, and then it won't try to detect the proxy settings.
Another option is to configure your DNS server to resolve "aptproxy",
rather than relying on /etc/hosts.
live well,
vagrant