5

I have a 250G disk on my Mac with around 100G in use. But the system reports only around 20G of free space. I'm using macOS 10.13.2. I have the problem at least since the upgrade to High Sierra, but probably also before.

"About This Mac" --> "Storage" reports that "System" is using around 180G. But if I check the complete disk, it looks like that:

$ sudo du -cxhd 1 /
  0B    /.HFS+ Private Directory Data
1.0K    /home
4.3G    /usr
4.2G    /.Spotlight-V100
1.0K    /net
 34G    /nix
  0B    /.PKInstallSandboxManager
  0B    /.PKInstallSandboxManager-SystemSoftware
2.6M    /bin
  0B    /Network
1.1M    /sbin
3.8G    /Library
  0B    /.Trashes
6.5G    /System
476K    /.fseventsd
du: /private/var/db/ConfigurationProfiles/Store: Operation not permitted
du: /private/var/folders/z7/[...]/0/SafariFamily: Operation not permitted
du: /private/var/folders/z7/[...]/0/com.apple.LaunchServices.dv: Operation not permitted
du: /private/var/folders/z7/[...]/0/com.apple.nsurlsessiond: Operation not permitted
du: /private/var/folders/z7/[...]/0/com.apple.routined: Operation not permitted
du: /private/var/folders/zz/[...]/0/com.apple.nsurlsessiond: Operation not permitted
8.0G    /private
8.6M    /.DocumentRevisions-V100
  0B    /.vol
 32G    /Users
 11G    /Applications
207M    /opt
5.0K    /dev
4.0K    /Volumes
  0B    /cores
104G    /
104G    total

df also says that only 20G are available:

$ df -h /
Filesystem     Size   Used  Avail Capacity iused               ifree %iused  Mounted on
/dev/disk1s1  234Gi  211Gi   20Gi    92% 4019132 9223372036850756675    0%   /

Any tool I was using (Finder, Disk Inventory X, etc.) shows more or less the same numbers like df and du.

Output of mount:

$ mount
/dev/disk1s1 on / (apfs, local, journaled)
devfs on /dev (devfs, local, nobrowse)
/dev/disk1s4 on /private/var/vm (apfs, local, noexec, journaled, noatime, nobrowse)
map -hosts on /net (autofs, nosuid, automounted, nobrowse)
map auto_home on /home (autofs, automounted, nobrowse)

I read and tested many, many things like:

... but with no success. So what could consume more than 100G of disk space without showing up in any tool?

Update

Running „First Aid“ in recovery mode: first aid

What does this error message mean?

error: btn:1: invalid key order (1) oid 440198 / oxid 114577
fsroot tree is invalid.

Update 2018-01-25

Another report of the same error: https://discussions.apple.com/thread/8246182 (but no answers, yet)

I'm pretty sure this file system error is the root cause for the missing disk space. But I have no idea how to fix that. I was hoping that 10.13.3 would maybe solve it, but it didn't change anything. I guess I need to reinstall...

  • Can't really offer too much help here, but if you edit many videos or anything like that - clear your iMovie video library. I had a similar issue where I had 250ish GB being taken up by something and I couldn't figure it out for a long time. It takes up more than you would expect. – Andre Jan 10 '18 at 23:13
  • Which tool from did you use? – Mark Jan 25 '18 at 12:56
  • @Mark for the filesystem check: disk-utility while in Recovery Mode (see image). For counting files, multiple programs, see above. – tlo Jan 25 '18 at 12:59
  • Sorry my comment is missing the important bot. Which tool from How can I figure out what's slowly eating my HD space? did you use and what does it show – Mark Jan 26 '18 at 15:29
5

It seems like the two most likely candidates are a mounted (shared) disk overwriting a location with large files, hiding them from your view, or large (or many many small) files that are held open by a process, but have already been deleted. If you haven't rebooted the computer yet, that's worth a shot, but also booting into recovery mode and running first aid on the disk might help. lsof | grep deleted might also reveal interesting information, if lsof is available on OSX (I assume it is, but I've never looked)

I've also noticed in my own use that if I use a tool like DiskInventory or Grand Perspective and there are other users on the system, they won't show the size of other users files if I don't have read access to them (reasonably so). If you have other users on your system, they may have large files in their home directory you're not seeing.

  • I rebooted the system several times already. The mounts look ok (I added the output to the question). I'll do the "first aid" in recovery mode later. Good point, thx! – tlo Jan 10 '18 at 14:55
  • I think there's also an option in Disk Utility to Erase Free Space, might be worth giving that a run if First Aid doesn't help – moneyt Jan 10 '18 at 16:01
  • 1
    A good option, as moneyt pointed out, is Grand Perspective, or Daisy Disk. These do a graphical mapping of your disk contents making it easy to find large files and folders. – jmh Jan 10 '18 at 17:58
  • See my update, it's very likely not files that consume the disk space (it would show up in one of the tools I used), but a file system error. – tlo Jan 25 '18 at 13:01
2

I finally reinstalled the system after erasing the volume. With a Time Machine backup it was more or less a smooth experience. Now I have 170G of free space.

tl;dr:

  • Missing disk space can be related to a broken filesystem
  • APFS tooling is currently really bad, you probably need to erase the volume and reinstall to fix any filesystem problem
0

I think I have found the answer to this. I've successfully solved my own issue of lost hd space which seems to have happened due to deleting g files over a network which deletes the files but leaves behind a hidden file called an smbdelete file. Here's how to get rid of it.

Go into terminal and type:. defaults write com.apple.finder AppleShowAllFiles YES

This shows all hidden files in OSX.

Hold down alt and right click on finder and select relaunch. Look for the smbdelete files and delete them. Your storage will reappear. The location of these files can be found by using the manage storage facility in OSX to look for folders that look larger in size than they should be. Mine were on the desktop so we're easy to find. Hope this helps

-1

I suffered a similar problem, only 800gb available from the 1tb.

to fix it, I boot up using ubuntu usb drive for macOS, then I can see the missing 200gb space.

I deleted both the 200gb and 800gb from ubuntu.

then boot up Mojave and the 1tb is all there.

hth.

-1

Commands given below resolved the issue for me. Listed and deleted local snapshot and it freed 230 GB on my machine.In step 2, you enter the date/time received from step 1.

$ tmutil listlocalsnapshots com.apple.TimeMachine.2019-01-28-143406   

$ tmutil deletelocalsnapshots 2019-01-28-143406  

$ tmutil listlocalsnapshots /

Make sure it shows no file

You must log in to answer this question.

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