LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 02-19-2018, 10:58 AM   #1
vincix
Senior Member
 
Registered: Feb 2011
Distribution: Ubuntu, Centos
Posts: 1,240

Rep: Reputation: 103Reputation: 103
identify HDD problem


Hi,
I've got thousands of lines in the course of a week like the following in /var/log/messages:
Code:
Feb 13 07:57:02 home kernel: ata1.00: exception Emask 0x0 SAct 0x40000000 SErr 0x0 action 0x0
Feb 13 07:57:02 home kernel: ata1.00: irq_stat 0x40000008
Feb 13 07:57:02 home kernel: ata1.00: failed command: READ FPDMA QUEUED
Feb 13 07:57:02 home kernel: ata1.00: cmd 60/08:f0:38:84:78/00:00:71:00:00/40 tag 30 ncq 4096 in#012         res 41/40:08:3a:84:78/00:00:71:00:00/00 Emask 0x409 (media error) <F>
Feb 13 07:57:02 home kernel: ata1.00: status: { DRDY ERR }
Feb 13 07:57:02 home kernel: ata1.00: error: { UNC }
Feb 13 07:57:02 home kernel: ata1.00: configured for UDMA/133
Feb 13 07:57:02 home kernel: sd 0:0:0:0: [sda] FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Feb 13 07:57:02 home kernel: sd 0:0:0:0: [sda] Sense Key : Medium Error [current] [descriptor]
Feb 13 07:57:02 home kernel: sd 0:0:0:0: [sda] Add. Sense: Unrecovered read error - auto reallocate failed
Feb 13 07:57:02 home kernel: sd 0:0:0:0: [sda] CDB: Read(10) 28 00 71 78 84 38 00 00 08 00
Feb 13 07:57:02 home kernel: blk_update_request: I/O error, dev sda, sector 1903723578
Feb 13 07:57:02 home kernel: ata1: EH complete
There seem to be only two sectors mentioned, the one above and more rarely sector 1534635077.
And I'm not quite sure about the status of my HDD which is rather old.
I've also run badblocks and I got this:
Code:
Checking blocks 0 to 976762583
Checking for bad blocks (read-only test): 767317536
767317537
767317538
767317539
951861788
951861789
951861790
951861791
done
Pass completed, 8 bad blocks found. (8/0/0 errors)
hdparm -I /dev/sda
Code:
ATA device, with non-removable media
	Model Number:       ST31000528AS
	Serial Number:      9VPAQ8X7
	Firmware Revision:  CC46
	Transport:          Serial
smartctl -A /dev/sda
Code:
smartctl 6.2 2017-02-27 r4394 [x86_64-linux-3.10.0-693.17.1.el7.x86_64] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF READ SMART DATA SECTION ===
SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   098   079   006    Pre-fail  Always       -       39847412
  3 Spin_Up_Time            0x0003   095   094   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   091   091   020    Old_age   Always       -       9525
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   069   060   030    Pre-fail  Always       -       124795853514
  9 Power_On_Hours          0x0032   069   069   000    Old_age   Always       -       27580
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   097   097   020    Old_age   Always       -       3119
183 Runtime_Bad_Block       0x0032   089   089   000    Old_age   Always       -       11
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   001   001   000    Old_age   Always       -       3186
188 Command_Timeout         0x0032   100   099   000    Old_age   Always       -       8590065776
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   077   049   045    Old_age   Always       -       23 (Min/Max 16/23)
194 Temperature_Celsius     0x0022   023   051   000    Old_age   Always       -       23 (0 10 0 0 0)
195 Hardware_ECC_Recovered  0x001a   043   013   000    Old_age   Always       -       39847412
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       3
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       3
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       1
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       26220775378866
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       311826828
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       4202092139
Where should I go from here?

Last edited by vincix; 02-19-2018 at 11:06 AM.
 
Old 02-19-2018, 04:12 PM   #2
RoLoR
Member
 
Registered: Feb 2018
Posts: 60

Rep: Reputation: Disabled
Best things to do in that situation is:

- Backup any important stuff that isn't backup-ed already.

- go to a store and buy a replacement for that failing drive before it die on you
 
Old 02-19-2018, 04:19 PM   #3
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, Debian 12 & Devuan
Posts: 9,486
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Hi:

I'm not good with fixing bad sectors but I'm sure others here are.

When I started seeing I/O errors I soon figured out that the HDD was going south so I replaced it and all is well now.

Here's a few links that look like a start.

https://www.techwalla.com/articles/h...ctors-in-linux

https://www.techwalla.com/articles/h...ctors-in-linux

I see in your profile "Centos" I know your not running Arch but I find their WiKi's helpful.
https://wiki.archlinux.org/index.php/S.M.A.R.T.

Does the os on the HDD your having trouble with boot?
 
1 members found this post helpful.
Old 02-19-2018, 04:55 PM   #4
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,786

Rep: Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216
The disk has only 3 bad sectors that have been detected thus far, and in terms of Power_On_Hours it's abot mid life (27580 hours is a little over 3 years), but I see it's a 2009 vintage drive, so by that measure it's getting a bit old. If you're in a mood to upgrade to a larger drive, by all means take this as a good time to replace it. Otherwise, take a look at the Bad block HOWTO for instructions on how to get the drive to remap those sectors and present a fault-free drive to the OS.
 
1 members found this post helpful.
Old 02-19-2018, 05:10 PM   #5
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524

Rep: Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015
All drive manufacturers offer free utilities to check, diagnose and repair their drives. I'd use one of those.

Last edited by AwesomeMachine; 02-20-2018 at 06:06 PM.
 
Old 02-20-2018, 02:23 AM   #6
vincix
Senior Member
 
Registered: Feb 2011
Distribution: Ubuntu, Centos
Posts: 1,240

Original Poster
Rep: Reputation: 103Reputation: 103
My data are backed up, so I'm not really worried about that. I'm actually more interested in how it behaves and how I could actually prolong its (NOT "it's", ffs )lifespan. I'll return after I've tested Ztcoracat's solution. By the way, your first link (which is useful, indeed) is the same as your second link and your third link doesn't work, but if I type "SMART" in the search box on wiki.archilinux, then I get there

Afterwards, I'll also have a look at rknichols's suggestion. Thanks!
 
Old 02-20-2018, 08:35 AM   #7
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,786

Rep: Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216Reputation: 2216
Quote:
Originally Posted by vincix View Post
and how I could actually prolong its (NOT "it's", ffs )lifespan.
If that's my grammar you're complaining about, I suggest you reread what I posted. Sorry about the typo in "abot", which of course should have been "about". Perhaps that confused you.
 
Old 02-20-2018, 08:40 AM   #8
vincix
Senior Member
 
Registered: Feb 2011
Distribution: Ubuntu, Centos
Posts: 1,240

Original Poster
Rep: Reputation: 103Reputation: 103
Quote:
Originally Posted by rknichols View Post
If that's my grammar you're complaining about, I suggest you reread what I posted. Sorry about the typo in "abot", which of course should have been "about". Perhaps that confused you.
It had nothing to do with whatever anyone wrote here. I didn't even notice your error, which belongs to a whole different category - it's just a common typo. I'm hardly a fluent speaker myself. I was just pointing out the fact that EVERYONE writes "it's" instead of "its". In the majority of articles about IT that I read on the internet this is how it's (or its?!) written and I find it... disturbing, because it makes no sense. And these are native speakers. But never mind that, I don't want to turn this thread into something else
 
Old 02-20-2018, 04:19 PM   #9
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, Debian 12 & Devuan
Posts: 9,486
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Quote:
Originally Posted by vincix View Post
My data are backed up, so I'm not really worried about that. I'm actually more interested in how it behaves and how I could actually prolong its (NOT "it's", ffs )lifespan. I'll return after I've tested Ztcoracat's solution. By the way, your first link (which is useful, indeed) is the same as your second link and your third link doesn't work, but if I type "SMART" in the search box on wiki.archilinux, then I get there

Afterwards, I'll also have a look at rknichols's suggestion. Thanks!
Sorry about that. Thanks for letting me know.

Let us know how things go:-
 
Old 02-20-2018, 06:07 PM   #10
AwesomeMachine
LQ Guru
 
Registered: Jan 2005
Location: USA and Italy
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524

Rep: Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015Reputation: 1015
See #5
 
Old 02-22-2018, 03:20 AM   #11
Soadyheid
Senior Member
 
Registered: Aug 2010
Location: Near Edinburgh, Scotland
Distribution: Cinnamon Mint 20.1 (Laptop) and 20.2 (Desktop)
Posts: 1,676

Rep: Reputation: 487Reputation: 487Reputation: 487Reputation: 487Reputation: 487
Sorry, just to end the grammar conflict, rknichols use of "it's" is correct.
Quote:
it's getting a bit old.
means "it is getting a bit old"
whereas "its lifespan" means the lifespan of "it"

I also get picky about your and you're. The first being " belonging to you", the second means "you are" Don't start me on to and too!

End of anal post! Off to lie down in a darkened room again!

Play Bonny!
 
Old 02-22-2018, 03:45 AM   #12
vincix
Senior Member
 
Registered: Feb 2011
Distribution: Ubuntu, Centos
Posts: 1,240

Original Poster
Rep: Reputation: 103Reputation: 103
Quote:
Originally Posted by Soadyheid View Post
Sorry, just to end the grammar conflict, rknichols use of "it's" is correct.
means "it is getting a bit old"
whereas "its lifespan" means the lifespan of "it"

I also get picky about your and you're. The first being " belonging to you", the second means "you are" Don't start me on to and too!

End of anal post! Off to lie down in a darkened room again!

Play Bonny!
I never said that his use of "it's" was incorrect. I'm sorry for the confusion - what I said had NOTHING to do with anything anyone has written in this thread. I guess I should have been clearer. It was just something that stuck in my mind and it was UNRELATED to anyone here Sorry for being ambiguous.
 
Old 02-22-2018, 11:49 AM   #13
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, Debian 12 & Devuan
Posts: 9,486
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Did using S.M.A.R.T. help vincix?

Installing and configuring S.M.A.R.T. in Centos

https://webpatron.net/en/blog/sysadm...tions-to-email

Here's the download:
https://sourceforge.net/projects/smartmontools/

Additional help and information
https://wiki.archlinux.org/index.php/S.M.A.R.T.
 
Old 02-22-2018, 03:13 PM   #14
vincix
Senior Member
 
Registered: Feb 2011
Distribution: Ubuntu, Centos
Posts: 1,240

Original Poster
Rep: Reputation: 103Reputation: 103
Hi,

I booted an ubuntu live cd and I tried using e2fsck -cfpv, but I can't see to be able to. I get "Cannot continue. Aborting". The hdd has two partitions, a simple ext4 boot partition (which I'm able to scan), and the second is actually LVM. I'm guessing the fact that it's lvm might have something to do with it. So where do I go from here? How can I scan a lvm partition without actually using it, i.e. outside the OS itself, with a live cd?
 
Old 02-22-2018, 03:22 PM   #15
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,026

Rep: Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632Reputation: 3632
I'm with the #5 idea too.
 
1 members found this post helpful.
  


Reply



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
Please help to identify the following problem? y_zl Linux - Security 2 01-05-2016 08:40 PM
Booting Problem. Windows and ubuntu on internal hdd. Centos on External USB hdd faisal59 Linux - Distributions 1 07-17-2013 08:19 AM
[SOLVED] Can't Identify my FREECOM HDD on my new Linux OS chicbrydie Linux - Hardware 6 10-03-2011 07:59 PM
Identify Problem, potentially Raid related. InJesus Linux - Hardware 1 04-02-2008 08:14 PM
Dual HDD Interface Problem, Linux on SATA, NTFS Part on IDE HDD LILO Not Loading Blade44 Linux - Hardware 2 02-01-2005 06:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:33 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration