LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 05-16-2011, 09:33 PM   #1
carlosinfl
Senior Member
 
Registered: May 2004
Location: Orlando, FL
Distribution: Debian
Posts: 2,896

Rep: Reputation: 73
How Do I Test My Hard Drive?


I notice a bunch of weird what appear to be hard drive related error messages on my Linux server:

Code:
May 16 19:07:38 ghost kernel: [ 3495.452698] ata3.00: configured for UDMA/33
May 16 19:07:38 ghost kernel: [ 3495.452706] ata3: EH complete
May 16 19:07:40 ghost kernel: [ 3497.380640] ata3.00: configured for UDMA/33
May 16 19:07:40 ghost kernel: [ 3497.380648] ata3: EH complete
May 16 19:07:44 ghost kernel: [ 3501.732973] ata3.00: configured for UDMA/33
May 16 19:07:44 ghost kernel: [ 3501.732983] ata3: EH complete
May 16 20:43:01 ghost kernel: [ 9218.929234] md: md2: resync done.
May 16 22:23:33 ghost kernel: [15250.068952] sshd (5073): /proc/5073/oom_adj is deprecated, please use /proc/5073/oom_score_adj instead.
Some more from 'dmesg':

Code:
[ 3294.792511] sd 2:0:0:0: [sda] Unhandled sense code
[ 3294.792514] sd 2:0:0:0: [sda]  Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[ 3294.792520] sd 2:0:0:0: [sda]  Sense Key : Medium Error [current] [descriptor]
[ 3294.792549] sd 2:0:0:0: [sda]  Add. Sense: Unrecovered read error - auto reallocate failed
[ 3294.792556] sd 2:0:0:0: [sda] CDB: Read(10): 28 00 3c 4e 99 80 00 04 00 00
[ 3294.792569] end_request: I/O error, dev sda, sector 1011784664
I don't know if this could be an indication that my hard drive(s) are about to fail. Can someone tell me if there's a way to test the drives or understand what's causing this error?
 
Old 05-17-2011, 12:59 AM   #2
DanceMan
Member
 
Registered: Mar 2009
Location: Vancouver BC
Posts: 64

Rep: Reputation: 21
Simplest and best way to check a hard drive's health is to run the manufacturer's test utility. And the best way to do this is to download and burn the Ultimate Boot CD and burn it to a cd. It's free, full of freeware utilities, including all the hdd test utilities, and it's a self booting cd with its own linux boot files. So it does not even need a functioning OS in the computer, just an optical drive capable of booting. These days you could probably put it on a flash drive.

Most of the test utilities will access the SMART data and look for error msgs, and then you can run a quick test and/or a full test. Almost never had a long test that produced a result different than the quick test. The tests will not damage the data on your drive.

For others reading this, if you have a Toshiba hdd, use one of the Seagate utilities.
 
Old 05-17-2011, 03:19 AM   #3
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
You can also run a smart long test 'smartctl -t long /dev/sda', then wait until it's done and check the result.
 
Old 05-17-2011, 09:08 AM   #4
segmentation_fault
Member
 
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 54
I had some errors that looked like these, the past few days. Mine also complained about "drive not ready" "software reset" and few more.
And yesterday, after an upgrade (debian squeeze) the system froze and never booted again. That moment I booted the "Hiren's boot cd" and run some tests.
All the manufacturers tests (seagate tools and wd tools, the disk is western digital) passed successfuly, all the smart utilities show that the drive is 100% healthy, BUT hdd regenerator (scans and repairs bad sectors) finds some bad sectors and around 1GB freezes, saying that the drive is not ready. Even if I start the scan past that sector it freezes again after some time. And it doesn't alwas freeze at the same sector, so it's not a particular sector that causes this.
Now I have backed up some important files and I'm gonna run a write-zeroes-to-disk aka low-level format and see how that goes.
However I have a strong feeling that the drive is left4dead...

UPDATE: Ok, the low-level format did not complete, but exited with error code 0115 (ICRC error), which means the data that was sent to the drive was corrupted. I will try a new sata cable, but I don't think that's the problem...

Last edited by segmentation_fault; 05-17-2011 at 09:26 AM. Reason: update
 
Old 05-17-2011, 10:19 AM   #5
H_TeXMeX_H
Guru
 
Registered: Oct 2005
Location: $RANDOM
Distribution: slackware64
Posts: 12,928
Blog Entries: 2

Rep: Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269Reputation: 1269
Just to be more clear, do backup your data, your HDD could be failing with messages like that.
 
Old 05-17-2011, 03:11 PM   #6
DanceMan
Member
 
Registered: Mar 2009
Location: Vancouver BC
Posts: 64

Rep: Reputation: 21
Doesn't sound good, but do try another cable. A fellow on another forum I frequent has run into bad Sata cables. But I doubt a bad cable would cause a problem to crop up partway through.

I've tried the "repair bad sectors" suggestions on drives, but never had success. I was stubborn enough to then run diagnostics again, and just found more bad sectors. Once you get those messages, it's game over. It isn't worth your time, and it isn't worth risking your data.
 
Old 05-17-2011, 04:16 PM   #7
segmentation_fault
Member
 
Registered: Sep 2008
Location: Ioannina, Greece
Distribution: Gentoo
Posts: 332

Rep: Reputation: 54
Of course I've made a backup
And my multimedia files (music etc) are on seperate disk. I just don't have a working computer, and my netbook can't drive the 24" full hd to watch a movie or something...
Anyway all tests have failed, tomorrow I'll buy a couble of cables just to be shure before the drive goes for recycling...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Test new hard drive(if its working) ansrewdps Linux - Newbie 5 02-25-2011 08:40 PM
Test integrity of External Hard drive? knappster Linux - Hardware 7 07-28-2009 11:45 AM
how to test/prove a hard drive? drakebasher Linux - Hardware 1 04-13-2007 05:59 PM
Test Hard Drive performance? voxel Linux - Hardware 7 09-07-2005 01:44 AM
Using linux as a hard drive test station rmarvin Linux - Newbie 0 06-10-2004 02:06 PM


All times are GMT -5. The time now is 01:25 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration