Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to see if a hard disk is being actively used right now (a hddled-like indicator) and what particular files are being accessed. How can I achieve this in command line with SSH?

share|improve this question

You can see the usage by using a tool like iotop. You can see a list of open files by using the command lsof.

share|improve this answer

In addition to iotop/lsof that was already mentioned, some other options include nmon, iostat, or atop. See this post on StackOverflow or this other question here on ServerFault.

share|improve this answer

Assuming you wanted to run the command through ssh and not just ssh directly to the machine. The command from ssh will look some thing like this:

ssh <hostname> lsof <options>

If you need this to run as root from a script, slightly fancy use of sudo and ssh keys should get you no requirement for a password. But be careful slightly to fancy use of sudo and ssh keys can just up and give anybody root access to your box.

share|improve this answer

Your Answer


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.