LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-22-2013, 04:29 AM   #1
marcelp1
Member
 
Registered: Nov 2010
Distribution: Debian
Posts: 35

Rep: Reputation: 1
XFS DISK Read error


I have a Seagate ST2000DL003-9VT166 2TB USB disk connected to my LinkStation which is formatted as XFS via the USB and suddenly got an error msg. in the log:

DISK Error Notification

HDD error occured
Disk(s) the error occurred:USB Disk 1

(sdc) READ sector:63 count:43
Disk writing error
Some data may not be recoverable.







So I have unpluged the HDD and connected it to my Debian Wheezy machine
and tried some diagnostics, but I am a newbie, so not sure how to repair it:

# fdisk -l

Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders, total 234441648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00088ebb

Device Boot Start End Blocks Id System
/dev/sda1 * 2048 224860159 112429056 83 Linux
/dev/sda2 224862206 234440703 4789249 5 Extended
/dev/sda5 224862208 234440703 4789248 82 Linux swap / Solaris
#


Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


# apt-get install xfsprogs

# xfs_check /dev/sdb1

xfs_check: /dev/sdb1 is not a valid XFS filesystem (unexpected SB magic number 0x00000000)
xfs_check: WARNING - filesystem uses v1 dirs,limited functionality provided.
xfs_check: read failed: Invalid argument
cache_node_purge: refcount was 1, not zero (node=0x9034c80)
xfs_check: cannot read root inode (22)
bad superblock magic number 0, giving up

# xfs_repair -n /dev/sdb1
Phase 1 - find and verify superblock...
bad primary superblock - bad magic number !!!

attempting to find secondary superblock...
.............................................
.............................................
.............................................
candidate secondary superblock...
verified secondary superblock...
would write modified primary superblock
Primary superblock would have been modified.
Cannot proceed further in no_modify mode.
Exiting now.


Should I run "xfs_repair /dev/sdb1" to have the Primary superblock modified?
Will I loose me data on that HDD if I run the command?
 
Old 11-23-2013, 08:24 AM   #2
Pearlseattle
Member
 
Registered: Aug 2007
Location: Zurich, Switzerland
Distribution: Gentoo
Posts: 999

Rep: Reputation: 142Reputation: 142
Maybe
You could take a full 1:1 copy before trying.

The command...
Code:
dd if=/dev/sdb1 of=/mydir/hddbackup_firstpartition.data
...will do a perfect copy.

Then you can just try to mount your copy with...
Code:
mount -v -o loop,noatime /mydir/hddbackup_firstpartition.data /mnt/somemountpoint
...which is not supposed to work.
If as expected it doesn't, then you can try to use the repair program on that copy with...
Code:
xfs_repair -n /mydir/hddbackup_firstpartition.data
...and see what happens.
 
1 members found this post helpful.
Old 12-04-2013, 03:25 AM   #3
marcelp1
Member
 
Registered: Nov 2010
Distribution: Debian
Posts: 35

Original Poster
Rep: Reputation: 1
I have managed to backup all the data from the data partition,
before anything else has been done with the drive
then used Hard Disk Sentinel 32-bit Linux console version:

wget http://www.hdsentinel.com/hdslin/hdsentinel_008.zip
unzip hdsentinel_008.zip -d ~/HDS
chmod 755 HDSentinel
sudo ./HDSentinel

HDD Device 2: /dev/sdc
HDD Model ID : WDC WD20EARS-00MVWB0
HDD Serial No: WD-WMAZA21234567
HDD Revision : 51.0AB51
HDD Size : 1907729 MB
Interface : Oxford/SAT USB/ATA
Temperature : 22 °C
Highest Temp.: 51 °C
Health : 11 %
Performance : 100 %
Power on time: 715 days, 17 hours
Est. lifetime: 13 days


and

smartctl --all /dev/sdc

smartctl 5.41 2011-06-09 r3365 [i686-linux-3.2.0-4-686-pae] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Model Family: Western Digital Caviar Green (Adv. Format)
Device Model: WDC WD20EARS-00MVWB0
Serial Number: WD-WMAZA21234567
LU WWN Device Id: 5 0014ee 6xx4x21x9
Firmware Version: 51.0AB51
User Capacity: 2,000,398,934,016 bytes [2.00 TB]
Sector Size: 512 bytes logical/physical
Device is: In smartctl database [for details use: -P show]
ATA Version is: 8
ATA Standard is: Exact ATA specification draft version not indicated
Local Time is: Mon Dec 2 18:01:33 2013 GMT
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status: (0x84) Offline data collection activity
was suspended by an interrupting command from host.
Auto Offline Data Collection: Enabled.
Self-test execution status: ( 0) The previous self-test routine completed
without error or no self-test has ever
been run.
Total time to complete Offline
data collection: (40800) seconds.
Offline data collection
capabilities: (0x7b) SMART execute Offline immediate.
Auto Offline data collection on/off support.
Suspend Offline collection upon new
command.
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: ( 2) minutes.
Extended self-test routine
recommended polling time: ( 255) minutes.
Conveyance self-test routine
recommended polling time: ( 5) minutes.
SCT capabilities: (0x3035) SCT Status supported.
SCT Feature Control supported.
SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE
1 Raw_Read_Error_Rate 0x002f 169 153 051 Pre-fail Always - 6369
3 Spin_Up_Time 0x0027 253 253 021 Pre-fail Always - 1050
4 Start_Stop_Count 0x0032 100 100 000 Old_age Always - 159
5 Reallocated_Sector_Ct 0x0033 190 190 140 Pre-fail Always - 202
7 Seek_Error_Rate 0x002e 200 200 000 Old_age Always - 0
9 Power_On_Hours 0x0032 077 077 000 Old_age Always - 17177
10 Spin_Retry_Count 0x0032 100 100 000 Old_age Always - 0
11 Calibration_Retry_Count 0x0032 100 100 000 Old_age Always - 0
12 Power_Cycle_Count 0x0032 100 100 000 Old_age Always - 157
192 Power-Off_Retract_Count 0x0032 200 200 000 Old_age Always - 156
193 Load_Cycle_Count 0x0032 001 001 000 Old_age Always - 2016949
194 Temperature_Celsius 0x0022 120 099 000 Old_age Always - 30
196 Reallocated_Event_Count 0x0032 174 174 000 Old_age Always - 26
197 Current_Pending_Sector 0x0032 001 001 000 Old_age Always - 65410
198 Offline_Uncorrectable 0x0030 200 197 000 Old_age Offline - 0
199 UDMA_CRC_Error_Count 0x0032 200 200 000 Old_age Always - 0
200 Multi_Zone_Error_Rate 0x0008 200 191 000 Old_age Offline - 0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
Num Test_Description Status Remaining LifeTime(hours) LBA_of_first_error
# 1 Conveyance offline Completed without error 00% 17117 -

SMART Selective self-test log data structure revision number 1
SPAN MIN_LBA MAX_LBA CURRENT_TEST_STATUS
1 0 0 Not_testing
2 0 0 Not_testing
3 0 0 Not_testing
4 0 0 Not_testing
5 0 0 Not_testing
Selective self-test flags (0x0):
After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.





How could the LinkStation NAS get that drive (Western Digital Caviar Green) to Health 11% / Est. lifetime: 13 days?
Are there any HDD tools to give me comprehensive overview what exactly is wrong with it?
 
  


Reply

Tags
xfs



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
After installation I get, Error 25: Disk read error, Press any key to continue ... mataitsane Linux - Newbie 5 06-06-2012 10:45 AM
Mount XFS file-system disk can't read superblock v1nc3ntlaw Linux - Hardware 7 04-27-2011 11:07 PM
GRUB Error 26: Disk Read Error (using grub4dos and ubuntu) Dark_Master Linux - Software 11 02-25-2007 07:42 AM
GRUB Error 26: Disk Read Error (using grub4dos and ubuntu) Dark_Master Linux - Newbie 2 11-07-2006 11:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:16 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