10

I am getting some weird errors with an ubuntu docker container: "Writing more data than expected (7643558 > 7643216)" Retrying the operations succeeded. I got this several times. I am running the ubuntu 16 ('created 2 weeks ago') container on a default boot2docker machine installed with docker toolbox. My setup is:

-Windows 7 in a corporate environment with an http proxy to access web content.

-default boot2docker VM on virtualbox machine created with docker toolbox and accessing the web through the corporate proxy

There are quite some hops from going out of the container to apt-get repositories.

Is this possible with apt-get?

Need to get 13.1 MB of archives.
After this operation, 53.5 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://archive.ubuntu.com/ubuntu xenial/main amd64 sgml-base all 1.26+nmu4ubuntu1 [12.5 kB]
Get:2 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libssl1.0.0 amd64 1.0.2g-1ubuntu4.1 [1122 kB]
Get:3 http://archive.ubuntu.com/ubuntu xenial/main amd64 libgeoip1 amd64 1.6.9-1 [70.1 kB]
Get:4 http://archive.ubuntu.com/ubuntu xenial/main amd64 libkrb5support0 amd64 1.13.2+dfsg-5 [30.7 kB]
Get:5 http://archive.ubuntu.com/ubuntu xenial/main amd64 libk5crypto3 amd64 1.13.2+dfsg-5 [81.0 kB]
Get:6 http://archive.ubuntu.com/ubuntu xenial/main amd64 libkeyutils1 amd64 1.5.9-8ubuntu1 [9904 B]
Get:7 http://archive.ubuntu.com/ubuntu xenial/main amd64 libkrb5-3 amd64 1.13.2+dfsg-5 [273 kB]
Get:8 http://archive.ubuntu.com/ubuntu xenial/main amd64 libgssapi-krb5-2 amd64 1.13.2+dfsg-5 [120 kB]
Get:9 http://archive.ubuntu.com/ubuntu xenial/main amd64 libicu55 amd64 55.1-7 [7643 kB]
Err:9 http://archive.ubuntu.com/ubuntu xenial/main amd64 libicu55 amd64 55.1-7
  Writing more data than expected (7643558 > 7643216)
Get:10 http://archive.ubuntu.com/ubuntu xenial/main amd64 libxml2 amd64 2.9.3+dfsg1-1 [696 kB]
Get:11 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libisc160 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [214 kB]
Get:12 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libdns162 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [877 kB]
Get:13 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libisccc140 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [16.3 kB]
Get:14 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libisccfg140 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [40.5 kB]
Get:15 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 libbind9-140 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [23.6 kB]
Get:16 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 liblwres141 amd64 1:9.10.3.dfsg.P4-8ubuntu1 [33.0 kB]
Get:17 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 bind9-host amd64 1:9.10.3.dfsg.P4-8ubuntu1 [38.4 kB]
Get:18 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 dnsutils amd64 1:9.10.3.dfsg.P4-8ubuntu1 [89.1 kB]
Get:19 http://archive.ubuntu.com/ubuntu xenial/main amd64 geoip-database all 20160408-1 [1678 kB]
Get:20 http://archive.ubuntu.com/ubuntu xenial/main amd64 krb5-locales all 1.13.2+dfsg-5 [13.2 kB]
Get:21 http://archive.ubuntu.com/ubuntu xenial/main amd64 xml-core all 0.13+nmu2 [23.3 kB]
Get:22 http://archive.ubuntu.com/ubuntu xenial/universe amd64 libproxychains3 amd64 3.1-7 [14.0 kB]
Get:23 http://archive.ubuntu.com/ubuntu xenial/universe amd64 proxychains all 3.1-7 [5582 B]
Fetched 5480 kB in 41s (133 kB/s)
E: Failed to fetch http://archive.ubuntu.com/ubuntu/pool/main/i/icu/libicu55_55.1-7_amd64.deb  Writing more data than expected (7643558 > 7643216)

E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
4
  • 1
    Is your corporate proxy doing content rewriting? :-(
    – roaima
    May 20, 2016 at 10:30
  • I don't know . How can I find out? It is a squid proxy and blocks sites like youtube. When it blocks the youtube page it listsa page saying that it is blocket with the thumbnail picture of the video in question. I is getting some content of the page to show that thumbnail. May 20, 2016 at 10:35
  • I'd recommend you ask your internal IT Servicedesk. Explain that you're getting unexpected content length changes in the data you're downloading (give the URL). If it is content rewriting they should be able to exclude archive.ubuntu.com (and others).
    – roaima
    May 20, 2016 at 10:38
  • I just rebuilt docker a couple of times and it worked. Jun 13, 2018 at 17:51

4 Answers 4

2

I ran into that problem but not in link with the system packages. I run my own build for my project and the server generates 70 packages.

If somehow the cache and the package repository get out of sync. then I get this error. (Especially if you recompile an already published package without changing its version first.)

In other words, apt-get gets two different set of information from two different locations and reacts by saying it cannot reconcile the data and just fails.

0
2

I ran into a similar problem while trying to update a Rancher installation:

sudo /usr/bin/apt-get dist-upgrade
E: Failed to fetch https://download.docker.com/linux/ubuntu/dists/xenial/pool/stable/amd64/containerd.io_1.2.10-2_amd64.deb  Writing more data than expected (19836216 > 19836188)

I got the same error when I tried

sudo apt install containerd.io

The problem went away after running

sudo apt update
1

Just for anyone else in the same predicament, as this question seems to be top of the search engine list for this problem. I had this error only on one client, and after trying many apt-based commands the only thing that fixed it was copying the relevant entry for that app from a working client's system.

Exact file and directory will obviously vary from config to config, but if the above answers fail to help have a snoop around /var/lib/apt/lists/ for files containing references to the problem package.

0

I had this problem too, with a different package but with ubuntu:16.04 in docker. I also have the proxy trouble in the company.

This worked for me: The package that had a problem was a dependency, not a package that I chose to install. Installing it manually did however work fine. After that I was able to install the desired package without problems.

Looking at your error you have a problem with the package "libicu55". In my case this was a dependency and not the one I was apt-get installing. Running "apt-get install libicu55" and then retrying to install the original package worked for me.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.