You are not logged in.

#1 2014-08-06 21:49:17

Convergence
Member
Registered: 2005-07-02
Posts: 377

External Hard drive problems

Quick note:  The background on this involves a raspberry pi.  However I am now working from my main rig, so the drive is now connected to my regular old x86 computer, which is why I'm not asking on the ARM bbs.

I've been using a raspberry pi as a headless NAS/torrent-box/media server/samba share for a long time now, and it's been great.  However, I've recently had a bunch of power fluxuations. Most of my computer hardware is on a big fat surge protector, and the energy is further protected by a robust power supply.  However my Pi NAS was not (my external drive was plugged into a surge protector though).  It started going wonky, and I started finding some corruption in my data.  Then it stopped working all together.

To make a long story short, there was corruption on both the SD card (/root) and the external (my samba share).  I tested the SD card on my main rig, and although it was corrupted, the SD card was salvageable (I tested it by writing to every bite, then reading the data back and seeing if there were any changes with a program called f3).

Then I started working on the external drive.  Plugging it into my main rig, dmesg gives:

[<ffffffff8119d79e>] SyS_open+0x1e/0x20
[624128.097043]  [<ffffffff8151c1e9>] system_call_fastpath+0x16/0x1b
[624131.905874] usb 4-4: reset high-speed USB device number 5 using ehci-pci
[624132.022968] sd 12:0:0:0: [sdd] Unhandled error code
[624132.022974] sd 12:0:0:0: [sdd]  
[624132.022977] Result: hostbyte=0x05 driverbyte=0x00
[624132.022979] sd 12:0:0:0: [sdd] CDB: 
[624132.022981] cdb[0]=0x28: 28 00 00 00 00 08 00 00 08 00
[624132.022988] end_request: I/O error, dev sdd, sector 8
[624132.022992] Buffer I/O error on device sdd, logical block 2
[624132.022995] Buffer I/O error on device sdd, logical block 3
[624854.126196] usb 4-4: USB disconnect, device number 5
[624854.127450] sd 12:0:0:0: [sdd] Synchronizing SCSI cache
[624854.127534] sd 12:0:0:0: [sdd]  
[624854.127539] Result: hostbyte=0x01 driverbyte=0x00
[624871.860853] usb 4-4: new high-speed USB device number 6 using ehci-pci
[624872.079934] usb-storage 4-4:1.0: USB Mass Storage device detected
[624872.080146] scsi13 : usb-storage 4-4:1.0
[624873.085431] scsi 13:0:0:0: Direct-Access     Seagate  External         SG12 PQ: 0 ANSI: 4
[624873.087286] sd 13:0:0:0: [sdd] 3907029164 512-byte logical blocks: (2.00 TB/1.81 TiB)
[624873.088194] sd 13:0:0:0: [sdd] Write Protect is off
[624873.088208] sd 13:0:0:0: [sdd] Mode Sense: 1c 00 00 00
[624873.089102] sd 13:0:0:0: [sdd] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[624873.109563]  sdd: sdd1 sdd2
[624873.113359] sd 13:0:0:0: [sdd] Attached SCSI disk
[624903.728034] usb 4-4: reset high-speed USB device number 6 using ehci-pci
[624934.762212] usb 4-4: reset high-speed USB device number 6 using ehci-pci
[624965.912537] usb 4-4: reset high-speed USB device number 6 using ehci-pci

  (Let me know if you want me to filter that or give you guys more of it.  It actually keeps spitting stuff out)


fsck just hangs when I attempt to run it on one of the partitions.
gparted hangs on startup if the device is plugged in.

I've read elsewhere that it could be related to the cable.  Unfortunately I only have one USB3.0 cable, but if you guys think that it might help, I can pick one up at Radio Shack.  What do you guys think?




By the way it was ext4


It's a very deadly weapon to know what you're doing
---  William Murderface

Offline

#2 2014-08-06 21:59:36

alphaniner
Member
From: Ancapistan
Registered: 2010-07-12
Posts: 2,810

Re: External Hard drive problems

If the external enclosure (which presumably contains a SATA drive) isn't in warranty, you could pop it open and test the drive directly.


But whether the Constitution really be one thing, or another, this much is certain - that it has either authorized such a government as we have had, or has been powerless to prevent it. In either case, it is unfit to exist.
-Lysander Spooner

Offline

#3 2014-08-06 22:01:05

Convergence
Member
Registered: 2005-07-02
Posts: 377

Re: External Hard drive problems

Good thinking!  I'll get on that.  It might be a while though.

edit:
Well, there's a slight problem. I think that taking this thing apart is a one way road.  There are no visible screws, I couldn't find any guides, but I did find this "taking this thing apart is pretty much impossible without braking the clips" in a review of the drive I found online.  That's not the end of the world, but it does mean that I'm not likely to do it today.  I've got other plans.  It also means that I will most likely be buying another drive anyway.  That's a bummer because I was planning on building a super NAS sometime in the next few months.

Last edited by Convergence (2014-08-06 22:24:29)


It's a very deadly weapon to know what you're doing
---  William Murderface

Offline

#4 2014-08-06 22:47:53

R00KIE
Forum Fellow
From: Between a computer and a chair
Registered: 2008-09-14
Posts: 4,734

Re: External Hard drive problems

Convergence wrote:

I did find this "taking this thing apart is pretty much impossible without braking the clips" in a review of the drive I found online.

If you can find pictures of where the latches are located maybe you can open the drive without breaking them. On another note, you should check the disk's smart attributes and see if everything looks ok, then I would recommend doing a full disk image, just in case your fix/recovery attempts make things worse.


R00KIE
Tm90aGluZyB0byBzZWUgaGVyZSwgbW92ZSBhbG9uZy4K

Offline

#5 2014-08-07 22:41:31

Convergence
Member
Registered: 2005-07-02
Posts: 377

Re: External Hard drive problems

I haven't had a chance to crack it open yet, but:

# smartctl -A /dev/sdd
smartctl 6.2 2013-07-26 r3841 [x86_64-linux-3.15.7-1-ck] (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   096   096   006    Pre-fail  Always       -       200188064
  3 Spin_Up_Time            0x0003   092   090   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   099   099   020    Old_age   Always       -       1146
  5 Reallocated_Sector_Ct   0x0033   100   100   036    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   067   060   030    Pre-fail  Always       -       4301174722
  9 Power_On_Hours          0x0032   089   089   000    Old_age   Always       -       10508
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       423
183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   001   001   000    Old_age   Always       -       184
188 Command_Timeout         0x0032   100   096   000    Old_age   Always       -       47 47 47
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   065   037   045    Old_age   Always   In_the_past 35 (15 75 37 29 0)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       376
193 Load_Cycle_Count        0x0032   088   088   000    Old_age   Always       -       25727
194 Temperature_Celsius     0x0022   035   063   000    Old_age   Always       -       35 (0 17 0 0 0)
195 Hardware_ECC_Recovered  0x001a   024   017   000    Old_age   Always       -       200188064
197 Current_Pending_Sector  0x0012   097   097   000    Old_age   Always       -       552
198 Offline_Uncorrectable   0x0010   097   097   000    Old_age   Offline      -       552
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       2437h+41m+09.684s
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       3958117834
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       1518493642

# smartctl -Hc /dev/sdd
smartctl 6.2 2013-07-26 r3841 [x86_64-linux-3.15.7-1-ck] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
Warning: This result is based on an Attribute check.
Please note the following marginal Attributes:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
190 Airflow_Temperature_Cel 0x0022   064   037   045    Old_age   Always   In_the_past 36 (15 75 37 29 0)

General SMART Values:
Offline data collection status:  (0x00)	Offline data collection activity
					was never started.
					Auto Offline Data Collection: Disabled.
Self-test execution status:      ( 121)	The previous self-test completed having
					the read element of the test failed.
Total time to complete Offline 
data collection: 		(  617) seconds.
Offline data collection
capabilities: 			 (0x73) SMART execute Offline immediate.
					Auto Offline data collection on/off support.
					Suspend Offline collection upon new
					command.
					No Offline surface scan supported.
					Self-test supported.
					Conveyance Self-test supported.
					Selective Self-test supported.
SMART capabilities:            (0x0003)	Saves SMART data before entering
					power-saving mode.
					Supports SMART auto save timer.
Error logging capability:        (0x01)	Error logging supported.
					General Purpose Logging supported.
Short self-test routine 
recommended polling time: 	 (   1) minutes.
Extended self-test routine
recommended polling time: 	 ( 266) minutes.
Conveyance self-test routine
recommended polling time: 	 (   2) minutes.
SCT capabilities: 	       (0x1083)	SCT Status supported.

It says that it "passed" but it does say that here has been errors.

This is mostly a bummer because now I'm out a media server... until I'm ready to fork out a hundred bucks for a new HD.

Last edited by Convergence (2014-08-08 03:28:05)


It's a very deadly weapon to know what you're doing
---  William Murderface

Offline

#6 2014-08-08 03:04:37

Convergence
Member
Registered: 2005-07-02
Posts: 377

Re: External Hard drive problems

Ok, I cracked it open, and plugged it in via SATA.  It's still broken. I started up gsmartcontrol to see if using a gui somehow drew a better picture for me.  For conveyance, short and long self-tests, it says:  "completed with read failure | 10% completed".  So it's having trouble reading it. 

Oh well, There was stuff of value on there, but I think I can replace most or all of it.  Beware plastic hard drive enclosures in the summer!

If anyone has any suggestions as far as data recovery (without taking it to a pro) I'd appreciate it.


It's a very deadly weapon to know what you're doing
---  William Murderface

Offline

#7 2014-08-08 09:35:22

R00KIE
Forum Fellow
From: Between a computer and a chair
Registered: 2008-09-14
Posts: 4,734

Re: External Hard drive problems

Your disk may still be salvageable but you need a second disk to make an image (or copy your data). I don't see anything specially bad that stands out, the only failed attribute is about temperature, that means the disk does not get enough cooling.

The Current_Pending_Sector and Offline_Uncorrectable attributes should both be zero, you might manage to make them go to zero if you can get all your data out and then wipe the whole disk (preferably by testing it with badblocks). After you do that, the smart self-tests should pass without problems.


R00KIE
Tm90aGluZyB0byBzZWUgaGVyZSwgbW92ZSBhbG9uZy4K

Offline

Board footer

Powered by FluxBB