LoginSignup
3
7

More than 5 years have passed since last update.

Macでディスク容量がいっぱいになってしまったときにすること

Last updated at Posted at 2017-06-03

image.png

ステータスバーのアップルマーク > このMacについて > ストレージ

から確認すればだいたい検討がつくが、エンジニアの場合は大抵「その他」が大半を占めているケースが多いのではないだろうか。

image.png

これだとどこが容量を占めているかわからないので、
CLIを使って調べる。
以下のコマンドを、ルートで実行する

sudo du -sh ./*|sort -nr

実行結果

344G    ./Users
 32K    ./Incompatible Software
 32G    ./Applications
 16G    ./private
 10G    ./Library
7.1G    ./System
6.5G    ./usr
4.5K    ./dev
4.0K    ./var
4.0K    ./tmp
4.0K    ./installer.failurerequests
4.0K    ./etc
4.0K    ./Volumes
2.5M    ./bin
1.0M    ./sbin
1.0K    ./net
1.0K    ./home
  0B    ./cores
  0B    ./Network

まずはルートで実行 → /Usersで実行 → 容量割合の大きかったディレクトリで実行 ・・・ を繰り返して、
削除/移動するファイル群を検討する

MacOSじゃなくてもUnixOS全般で使えるので覚えておいて損はない

3
7
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
7