6

Something very bizarre has happened.

Today I upgraded to Mavericks. Before the upgrade my 64GB SSD reported about 5GB free. After the upgrade it reports 18GB free.

While this is fantastic, could someone tell me what is going on?

My initial thought is that there may have been 8GB swap space (I have 8GB RAM) which the upgrade may have freed, but closing the lid and subsequently opening it again has not made any impression. I still have 18GB free.

  • I had ~10GB freed up on my SSD. – Daniel Oct 24 '13 at 20:37
4

ETA: while the guesses below all stand, here’s a better one from Marceil Weiher:

@rentzsch Have you checked with "df" vs. looking in Finder? I think 10.9 subtracts the space for mobile Time Machine from used in latter.

Marcel Weiher (@mpweiher) on Twitter

I’ve done some poking around on the machines I have lying around, and I think this is plausible and probably correct.

If you use Time Machine, that’s probably your answer.


Without seeing your system, it’s hard to know, but here are some suggestions:

  • The Mavericks installer is ~5GB in size, but it gets deleted once you’ve finished upgrading. When did you take the first reading? Perhaps you’ve lost the 5GB installer file (which replaces a lot of existing system files, so it doesn’t add 5GB to the system files), which would contribute to the difference.

  • Caches (temporary files) often get purged during an OS update. I have ~3GB of caches on my Mac, which would significantly free up space if that happened. Perhaps you had a lot of cache files to begin with?

  • Do you use Time Machine? Starting with Mountain Lion, Apple started keeping backups on your local disk, and writing them to an external drive when you plug it in. Assuming you plugged in your backup drive before you did the update1, it might just have purged all those local backup files and saved some space.

1 You did, right?

  • Backup / Time Machine, me? Never! I've only got my last year's work on it :-) – P i Oct 24 '13 at 21:27
  • I took the first reading before embarking on the whole process. In fact I was amazed it didn't complain that I had insufficient space to hold the installer. – P i Oct 24 '13 at 21:28
  • 2
    To add: Apple handled swap files differently in Mountain Lion and below. It could take up to 8GB somewhere in /var or /tmp – Enrico Susatyo Oct 26 '13 at 1:26
  • Finder has always counted local snapshots as free space, and Time Machine has actually never moved them to the external drive. This might have been a feature that was dropped before release, because it's a very common misconception. They stay on the local disk and get pruned when free space drops below 20%. See How do local TimeMachine backups work exactly? – gabedwrds Nov 5 '13 at 3:52
1

In relation to alexwlchan's answer:

Actually I believe the difference between what Finder reports compared to df is that Finder as of Moutain Lion (or even Lion?) reports disk space in multiples of 1000 (i.e 1kB is 1000B, as opposed to 1024B). df, having its roots in UNIX, I believe still uses the power of two system. In the man for df you'll see:

 -b      Use (the default) 512-byte blocks.  This is only useful as a way
         to override an BLOCKSIZE specification from the environment.

 -g      Use 1073741824-byte (1-Gbyte) blocks rather than the default.
         Note that this overrides the BLOCKSIZE specification from the
         environment.

 -H      "Human-readable" output.  Use unit suffixes: Byte, Kilobyte,
         Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the
         number of digits to three or less using base 10 for sizes.

 -h      "Human-readable" output.  Use unit suffixes: Byte, Kilobyte,
         Megabyte, Gigabyte, Terabyte and Petabyte in order to reduce the
         number of digits to three or less using base 2 for sizes.

 -k      Use 1024-byte (1-Kbyte) blocks, rather than the default.  Note
         that this overrides the BLOCKSIZE specification from the environ-
         ment.

 -m      Use 1048576-byte (1-Mbyte) blocks rather than the default.  Note
         that this overrides the BLOCKSIZE specification from the environ-
         ment.

therefore, if you run df -H you might see similar numbers to what Finder reports, but normally (i.e. when df is invoked with no options, or as df -b, df -k, df -m, df -g or df -h) you'll see number based on power of 2.

In relation to the original question - I've also noticed around 13GB more disk space. I think this may mean that Mavericks comes with even less bloat, or maybe that more stuff is compressed on the disk compared to ML?

  • Finder has used multiples of 10 since 10.6. Local snapshots (which were added in 10.7) have never been counted as used disk space in Finder. – Lri Oct 28 '13 at 11:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .