As mentioned by Michael Clark in his post Finder Security Bug or Feature?, the freeware application WhatSize is a quick and easy tool for measuring the size of a given folder and all subfolders and files within it. But WhatSize can only measure based on the permissions of the user who launches it, so you will not be able to measure the size of other user accounts nor folders with special permissions like the root level ‘private’ or ‘.Spotlight-V100′ or other directories inside /System. But here is a way for WhatSize to measure every file on your HD, regardless of permissions:
- Launch Terminal and type sudo followed by a space
- Right-click on the WhatSize application and choose Show Package Contents
- Open the Contents/MacOS folder within to find the WhatSize unix executable file
- Drag that file onto the Terminal window and from within that window, press return
- Enter your administrative password when prompted
The Terminal will fill with some code and WhatSize will now launch, seemingly normally. The difference is that it now has superuser privileges and can read every directory on your hard drive if you ask it to measure. You might be surprised at the difference between folder sizes, especially if you have multiple user accounts on your machine.
But be careful while you’re looking around in this way! Because if you choose a file and hit the Delete button, WhatSize will delete it as the root user and it won’t go in your user account’s Trash to be emptied. I recommend using the Reveal in Finder command and then sending the file to the trash from the Finder, where you’re using your regular user permissions.
Also, don’t close the Terminal window while you’re still running WhatSize, or it will quit WhatSize. Instead, use WhatSize’s File>Quit command, then close the Terminal window.
So if you really, truly want to know exactly what all your space is being used for, run WhatSize with the Terminal’s sudo command.
great tip Eddie!
Another great tool – a personal fav – for great understanding of where your hard drive space has gone is JDiskReport. It’s on OS X and Windows (it’s java based). It ran well enough on G4s, but SCREAMS on Intel. Great for visualizing the space and drilling down on things.
man du? :)
Can’t you do the same thing by changing to the List view in the Finder and then pressing CMD-J and selecting “Calculate all sizes”. This will show all sizes for the folder and all files that are under that folder.
No, you cannot do the same thing in the Finder. First, not all directories are visible in the Finder. For example, the root-level directory named “private” (which was mentioned in the post). That directory alone could be using 1.61GB of space and you wouldn’t know it by browsing around in the Finder. Also, you can’t use the Finder to browse around other user accounts. Finally, WhatSize uses a column view for easier navigation, sorts the listings by size and uses color-coding for quick visual clues as to what is big and what isn’t.
Ah, I see. I don’t usually don’t go poking around in the hidden folder on my Mac. I normally just switch to List view and start pruning.
In any case, it’s a nice app, though.
You might want to check out OmniDiskSweeper from the OmniGroup. I actually prefer its interface. The free version doesn’t allow you to delete files directly from the app, but if you really want a delete button you can get one for $15. Or you can just delete files from the Finder if you can tolerate the inconvenience.
I use the freeware tool GrandPerspective to see a visual representation of my hard drive. It shows most everything, though this tip sounds more comprehensive.
How can i become a saint?
I’d like to mention my favorite file size app: DiskInventoryX http://www.derlien.com/
Great little freeware app that displays files comparatively.
WhatSize is no longer freeware. It went commercial a few weeks ago and became nagware … :(