`apt-get upgrade` is going to free more space than in entire filesystem


#1

Debian Jessie. Did :

apt-get update followed by apt-get upgrade

Then got:

Reading package lists… Done
Building dependency tree
Reading state information… Done
Calculating upgrade… Done
The following packages will be upgraded:
apache2 apache2-bin apache2-data apache2-dev apache2-doc
apache2-suexec-custom apache2-utils bind9 bind9-host bind9utils
debian-archive-keyring dnsutils host libapache2-mod-passenger libbind9-90
libc-bin libc-dev-bin libc6 libc6-dev libdns-export100 libdns100 libexpat1
libexpat1-dev libffi6 libgcrypt20 libgnutls-deb0-28 libgnutls-openssl27
libgraphite2-3 libirs-export91 libisc-export95 libisc95 libisccc90
libisccfg-export90 libisccfg90 liblwres90 libtiff5
linux-image-3.16.0-4-amd64 linux-libc-dev locales multiarch-support openvpn
passenger passenger-dev passenger-doc python-acme python-cryptography
usermin webmin webmin-virtual-server webmin-virtual-server-theme
50 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 89.7 MB of archives.
After this operation, 16.7 GB disk space will be freed.
Do you want to continue? [Y/n] n
Abort.

I panicked at the 16.7 GB it offered to free up, as I’ve only got 13.xGB on that filesystem.

Any ideas?
Is there anything I can poke to see what it’s planning to do in more detail?

root@mh2:~# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/dm-0 14286320 9724576 3812996 72% /
udev 10240 0 10240 0% /dev
tmpfs 411736 41704 370032 11% /run
tmpfs 1029332 0 1029332 0% /dev/shm
tmpfs 5120 4 5116 1% /run/lock
tmpfs 1029332 0 1029332 0% /sys/fs/cgroup
/dev/vda1 240972 22314 206217 10% /boot
/dev/mapper/archive-backups 46314480 17636280 26302520 41% /mnt/backups


#2

If it is jessie, you can use apt upgrade instead of apt-get upgrade and you might find a different answer…


#3

Still the same.

This is a relatively new and clean install of Jessie (some months old). I’d be really surprised if something’s really wrong, but I’d like to have a bit more confidence before letting it rip.

I did see someone with almost the same exact issue on one of the IRC channels, but the just disappeared before an answer came up.


#4

I must admit that I rarely notice that figure, and I don’t remember ever caring. And I don’t know the code that does that calculation, but as it only wants to upgrade packages I would guess that calculation is way off, and go ahead.


#5

Me too! My mistake may have been to not just hit return as I usually do.


#6

Now this is better!

I just did an apt-get install webmin usermin webmin-virtual-server webmin-virtual-server-theme

and now:

root@mh2:~# apt-get upgrade
Reading package lists… Done
Building dependency tree
Reading state information… Done
Calculating upgrade… Done
The following packages will be upgraded:
apache2 apache2-bin apache2-data apache2-dev apache2-doc
apache2-suexec-custom apache2-utils bind9 bind9-host bind9utils
debian-archive-keyring dnsutils host libapache2-mod-passenger libbind9-90
libc-bin libc-dev-bin libc6 libc6-dev libdns-export100 libdns100 libexpat1
libexpat1-dev libffi6 libgcrypt20 libgnutls-deb0-28 libgnutls-openssl27
libgraphite2-3 libirs-export91 libisc-export95 libisc95 libisccc90
libisccfg-export90 libisccfg90 liblwres90 libtiff5
linux-image-3.16.0-4-amd64 linux-libc-dev locales multiarch-support openvpn
passenger passenger-dev passenger-doc python-acme python-cryptography
46 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 62.8 MB of archives.
After this operation, 489 kB disk space will be freed.
Do you want to continue? [Y/n]

I think I’m going to say ‘Y’ this time.


#7

It worked.

It looks like the manual upgrade of a few non-critical packages returned things to sanity.

All upgraded.