How To See Disk Usage On Mac

broken image


Hard drives, SSDs, flash drives, SD cards and so on. All storage solutions that will, sooner or later, run out of space. When they do, you will probably ask yourself where did all the space go?

  1. Mac Check Disk Usage
  2. How To See Disk Usage On Mac Os

To answer that question you can use a disk usage viewing tool. There are various third party commercial tools that you can use, but if you're running Linux or macOS you can take advantege of the terminal which comes with built-in tools or use third party free and open source tools.

ALSO READ HOW TO: Create Time-Saving Aliases

1. Using du and df

See real-time CPU, network, or disk status in the Dock. It's easy to keep an eye on your system status without even looking at the Activity Monitor window—you can monitor your CPU, network, or disk usage as a live graph right in the Dock. How to see your system status in the Dock. Launch Finder and then open a new window on Finder. On the sidebar of the window, go ahead and choose your Mac's hard disk and click it once. Av converter for mac. And then, from the File menu, go ahead and choose 'Get Info'. After that, you will be able to see on your screen the available disk space that you have on your Mac's hard drive.

  1. Best for: checking whether a disk is about to fail. The first handy thing you.
  2. Getting disk usage information on a Mac is often gathered by selecting a file, directory, or hard drive and hitting Command-I for Get Info, then appears a nice GUI interface with extended information about the selected object including disk usage.

These are two standard Unix programs that complement eachother. du stands for disk usage and df stands for disk free.

To use these commands, you can execute them as is (i.e du or df ) or read the manual with man df and man du to see all the options.

2. Using dust

Dust is, as the developer puts it, like du but more intuitive. Dust is meant to give you an instant overview of which directories are using disk space without requiring sort or head.

Install dust:

Jul 17, 2020 View CPU, RAM, Disk, Network Usage The most convenient place to monitor system stats from is the menu bar. Naturally, you need a menu bar app that can display these stats. We recommend using a free, open-source app called Stats.

How To See Disk Usage On Mac
  • Linux: cargo install du-dust or download binary ( Arch users can find dust in AUR )
  • macOS: using Homebrew. brew install dust or download binary
  • Windows: download binary ( NOTE: I'm not sure how the Windows binary works. I don't have any Windows machines, not even a VM )

Usage:

3. DUC – Dude, where are my bytes

Mac Check Disk Usage

Duc is a collection of tools for indexing, inspecting and visualizing disk usage. Duc maintains a database of accumulated sizes of directories of the file system, and allows you to query this database with some tools, or create fancy graphs showing you where your bytes are.

Install DUC:

  • Linux: on Debian/Ubuntu based systems use sudo apt install duc . Arch users can find duc in AUR. Everybody else can compile it from the source code.
  • macOS: using Homebrew. brew install duc

Usage:

Duc comes with a command line tool called duc, which is used to create, maintain and query the disk usage database. To see a list of available commands run duc help or run man duc for an extensive documentation.

First you need to index a directory you want to run duc against. It can be / , /usr or /home/username. This will create a database on ~/.duc.db.

NOTE: macOS users will have to index /Users/username instead of /home/username and I see no point in indexing just /usr How to unzip files on mac 2019.

Once the desired directory is indexed, you can list all files and directories , showing relative file sizes in a graph with duc ls -Fg /indexed/directory

However, duc comes with an UI and a GUI interface. Which makes duc even more useful. To show the UI interface you will need to run duc ui /indexed/directory. This will return the ncurses console interaface which can be navigated with the keyboard.

To start the graphical interface and explore the filesystem using a sunburst graph run duc gui /indexed/directory. This interface can be navigated with the mouse ( scroll to zoom in and out, and click to select ).

df is a great tool for checking the amount of free space on a disk (and the amount that's taken). df has a number of options for ways to view the output and can even look at free iNodes and blocks rather than just showing free space. However, df is going to come up short if you're hunting for where all your free space went within a given volume.For this, look to du. du is a great tool for checking disk utilization at more of a directory level. For example, the following command will show you how much space is being taken up by each application in the the /Applications directory:
du -d 1 /Applications/
Now run the command without the -d 1:
du /Applications/
The -d flag limits the depth that the command will traverse. By specifying 0 you would only see the files of a given directory, whereas if you specify -d 2 then you will be shown the sizes of your child directories from the path you specified and their children (since that's two). You can go as deep as you want with the depth setting, but the data returned by the command can be too much, at times. Also, the longer it will take for the command to complete as it's calculating more and more data.Some other flags that are useful are -x and -H. These will traverse mount points and symbolic links, respectively (both of which are not followed by default). This can help to keep your command's output limited to the host and volume of directories underneath the specified parent directory.If you're interested in seeing way to much information, try just running:
du -a

How To See Disk Usage On Mac Os

If you suddenly have only 1k of free space available, a series of du commands can turn information about where all of your data is in no time.



broken image