Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have my OS installed on a small SSD and most of my data on a large HDD. My HDD will spin up every fifteen minutes or so even if I am not doing anything. I want to find out who is causing it to spin up so I can either move its stuff back or tell it to stop.

share|improve this question
add comment

1 Answer 1

up vote 4 down vote accepted

You can use find to find out which files have been accessed. E.g. find /hdd/mount/path -cmin -15 will show you the files accessed in the last 15 minutes. Of course you have to enter the right path where your HDD is mounted. Otherwise it will look for files in the whole system. Maybe this gives you a hint. If you have no idea what process accessed the files, you can also find out exactly.

Another tool that could be usefull is iotop. You have to install it first:

sudo apt-get install iotop

Then you can run

sudo iotop -m /hdd/mount/path

to see which processes are accessing a specific mount path or

sudo iotop -f /path/to/file

to see which processes are accessing a specific file. The downside is that you have to watch it and wait for the access to happen.

share|improve this answer
1  
Just what I was looking for. A note on find: -cmin will show only files that were changed where -amin shows files that were just accessed as well. That's what worked for me. –  Bill Sep 10 '13 at 9:27
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.