[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#955429: possiblity of using a different download agent like wget in bad internet connections



Package: apt, apt-cacher-ng
Severity: wishlist

I have to use a bad internet connection that keeps breaking between downloads of large files (it has become worse after the covid-19 lockdown), but those same files are downloaded by wget just fine, ie, it is can easily resume after a short breakage.

For example using wget, this file was downloaded at a single try with wget coping with breakages in between,

sudo -u apt-cacher-ng wget http://deb.debian.org/debian/pool/main/g/golang-1.14/golang-1.14-go_1.14-2~bpo10+1_amd64.deb --2020-03-31 21:31:23-- http://deb.debian.org/debian/pool/main/g/golang-1.14/golang-1.14-go_1.14-2~bpo10+1_amd64.deb Resolving deb.debian.org (deb.debian.org)... 151.101.114.133, 2a04:4e42:3::645 Connecting to deb.debian.org (deb.debian.org)|151.101.114.133|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 49760864 (47M) [application/x-debian-package]
Saving to: ‘golang-1.14-go_1.14-2~bpo10+1_amd64.deb’

golang-1.14-go_1.14- 100%[======================>] 47.46M 262KB/s in 6m 41s

2020-03-31 21:38:05 (121 KB/s) - ‘golang-1.14-go_1.14-2~bpo10+1_amd64.deb’ saved [49760864/49760864]

where as apt with apt-cacher-ng files multiple times (just one example package but it happens with many large packages making it really frustrating),

Get: 1 http://deb.debian.org/debian buster-backports/main amd64 golang-1.14-go amd64 1.14-2~bpo10+1 [49.8 MB] Err http://deb.debian.org/debian buster-backports/main amd64 golang-1.14-go amd64 1.14-2~bpo10+1
 Bad header line Bad header data [IP: 127.0.0.1 3142]
Get: 2 http://deb.debian.org/debian buster-backports/main amd64 golang-go amd64 2:1.14~1~bpo10+1 [23.9 kB] Err http://deb.debian.org/debian buster-backports/main amd64 golang-go amd64 2:1.14~1~bpo10+1
 Hash Sum mismatch
Hashes of expected file:
- SHA256:547b2814a4ff0a0478951e60611589e68531716b60c5ea46c4b25792bc8f6e66
- Filesize:23880 [weak]
Hashes of received file:
- SHA256:8563eb3b5b3dbd88790d4fa40e4e1378aaa0713277ab9b1e2e763fd9bd5cd832
- Filesize:23880 [weak]
Last modification reported: Mon, 16 Mar 2020 14:57:23 +0000

Get: 3 http://deb.debian.org/debian buster/main amd64 golang-golang-x-tools amd64 1:0.0~git20190125.d66bd3c+ds-4+b1 [32.6 MB] Err http://deb.debian.org/debian buster/main amd64 golang-golang-x-tools amd64 1:0.0~git20190125.d66bd3c+ds-4+b1
 Hash Sum mismatch
Hashes of expected file:
- SHA256:5cce1cbd14b5f2d0833a491173cfeb62a80ee6b78f73eb49896d6046572ad5f9
- MD5Sum:6123b2748ab31b5c9f60281654a876c2 [weak]
- Filesize:32644448 [weak]
Hashes of received file:
- SHA256:713ee8bbe7dbb2dc0fface84055df483f6a5cb54328b2fce7daf157a6e07b330
- MD5Sum:b64064be5fda9678d7a6c71c3d118d15 [weak]
- Filesize:32644448 [weak]
Last modification reported: Sat, 08 Jun 2019 09:58:38 +0000

Fetched 32.7 MB in 5s (6429 kB/s)
E: Failed to fetch http://deb.debian.org/debian/pool/main/g/golang-1.14/golang-1.14-go_1.14-2~bpo10+1_amd64.deb: Bad header line Bad header data [IP: 127.0.0.1 3142] E: Unable to fetch some packages; try '-o APT::Get::Fix-Missing=true' to continue with missing packages

On a search I found this, but this is not really meant for this situation,
https://www.debian.org/doc/manuals/apt-offline/ch3.en.html

Would it be possible to configure apt to use wget automatically to not fail when connection breaks for short periods as evidently something wget can manage well?

I'm not sure if it is apt or apt-cacher-ng that is breaking here, hense opening against both.


Reply to: