domingo, 14 de febrero de 2010

Space is being consumed too fast? Find where!

You've found hat some process (don't know which) is eating up too much space too fast in one of your partitions and don't know where? Just yesterday I found a simple way to figure it out.

Suppose you want to check the partition where you have /home (which is in a separate partition from /, right?) where space is been eaten up too fast.

Run this simple command:

find /home -mount -type f -exec ls -s {} ';' > list_of_files1.txt

After it finishes running, wait for a little while (30 seconds, a minute, your call) and run the same thing outputting to a different file:

find /home -mount -type f -exec ls -s {} ';' > list_of_files2.txt

To find out what's going on, run a simple diff (a tool present in I guess every GNU/Linux system... if not unix) between both files and you should be able to see what's going on.

diff list_of_files1.txt list_of_files2.txt

You're welcome!

5 comentarios:

  1. @alvare#ClrnD: That's a good one. I had heard of iotop but had never used it. Thank you, pal!

    ResponderEliminar
  2. Este comentario ha sido eliminado por un administrador del blog.

    ResponderEliminar
  3. Este comentario ha sido eliminado por un administrador del blog.

    ResponderEliminar