Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
omv:disk-check [2015/11/06 02:32]
admin
omv:disk-check [2015/11/12 16:45] (current)
admin [Hard Drives Health Checks]
Line 1: Line 1:
 ====== Hard Drives Health Checks ====== ====== Hard Drives Health Checks ======
  
-When one builds a NAS, specifically on a tight budget, it might well happen that used hard drives are used to fill the hard disk bay...+When one builds a NAS, specifically on a tight budget, it might well happen that "​second hand" ​hard drives are used to fill the hard disk bay...
  
 One important thing to do before trusting those drives to safely store your precious data is to check their health. Here are a few command tools that can be used to performs such checks. One important thing to do before trusting those drives to safely store your precious data is to check their health. Here are a few command tools that can be used to performs such checks.
  
-The following was collected ​in [[http://​linuxpoison.blogspot.be/​2008/​01/​howto-check-disk-drive-for-errors-and.html|this blogspot article]], as well as in [[http://​linoxide.com/​linux-how-to/​how-to-fix-repair-bad-blocks-in-linux/​|this ​LinOxyde ​one]].+The following was collected ​from [[http://​linuxpoison.blogspot.be/​2008/​01/​howto-check-disk-drive-for-errors-and.html|this blogspot article]], as well as from [[http://​linoxide.com/​linux-how-to/​how-to-fix-repair-bad-blocks-in-linux/​|this one on LinOxyde]].
  
 ===== badblocks ===== ===== badblocks =====
Line 15: Line 15:
 </​code>​ </​code>​
  
-badblocks will check a hard drive and log defective sectors to a file that can be used with other programs, like mkfs, so that they will be locked out of usage.+badblocks will check a hard drive and log defective sectors to a file that can be used with other programs, like //**mkfs**//, so that they will be locked out of usage.
 <​code>​ <​code>​
 > sudo badblocks -v /dev/hda1 > hda1-bad-blocks > sudo badblocks -v /dev/hda1 > hda1-bad-blocks
 +</​code>​
 +
 +//​badblocks//​ isn't particularly verbose, so if one wants to (more or less) monitor it's activity, iostat can help visualize disk activity:
 +<​code>​
 +> sudo apt-get install sysstat
 +</​code>​
 +
 +To monitor activity per disk:
 +<​code>​
 +> sudo iostat -xd <update interval in seconds>
 +</​code>​
 +
 +To monitor activity per partition:
 +<​code>​
 +> sudo iostat -pxd <update interval in seconds>
 </​code>​ </​code>​