Solved

Bad ext4 disk

Posted on 2015-01-07
6
291 Views
Last Modified: 2015-01-16
root@server:~# smartctl -s on -a /dev/sde
smartctl 5.40 2010-07-12 r3124 [x86_64-unknown-linux-gnu] (local build)
Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Device Model:     ST2000DM001-1CH164
Serial Number:    W2F0TBTR
Firmware Version: CC26
User Capacity:    2 000 398 934 016 bytes
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  ATA-8-ACS revision 4
Local Time is:    Sun Jan  4 20:59:52 2015 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF ENABLE/DISABLE COMMANDS SECTION ===
SMART Enabled.

=== START OF READ SMART DATA SECTION ===




SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
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:                 ( 625) 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:        ( 255) minutes.
Conveyance self-test routine
recommended polling time:        (   2) minutes.
SCT capabilities:              (0x3085) SCT Status supported.

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   117   094   006    Pre-fail  Always       -       128198392
  3 Spin_Up_Time            0x0003   099   093   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       49
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       128
  7 Seek_Error_Rate         0x000f   060   060   030    Pre-fail  Always       -       4296024583
  9 Power_On_Hours          0x0032   083   083   000    Old_age   Always       -       15097
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       37
183 Runtime_Bad_Block       0x0032   081   081   000    Old_age   Always       -       19
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   001   001   000    Old_age   Always       -       358
188 Command_Timeout         0x0032   090   016   000    Old_age   Always       -       326427803805
189 High_Fly_Writes         0x003a   099   099   000    Old_age   Always       -       1
190 Airflow_Temperature_Cel 0x0022   069   056   045    Old_age   Always       -       31 (Lifetime Min/Max 29/38)
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       -       26
193 Load_Cycle_Count        0x0032   083   083   000    Old_age   Always       -       34046
194 Temperature_Celsius     0x0022   031   044   000    Old_age   Always       -       31 (0 20 0 0)
197 Current_Pending_Sector  0x0012   001   001   000    Old_age   Always       -       23656
198 Offline_Uncorrectable   0x0010   001   001   000    Old_age   Offline      -       23656
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       16720307683795
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       3246002700
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       5817657454

25132023

SMART Error Log Version: 1
ATA Error Count: 708 (device log contains only the most recent five errors)
        CR = Command Register [HEX]
        FR = Features Register [HEX]
        SC = Sector Count Register [HEX]
        SN = Sector Number Register [HEX]
        CL = Cylinder Low Register [HEX]
        CH = Cylinder High Register [HEX]
        DH = Device/Head Register [HEX]
        DC = Device Command Register [HEX]
        ER = Error register [HEX]
        ST = Status register [HEX]
Powered_Up_Time is measured from power on, and printed as
DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
SS=sec, and sss=millisec. It "wraps" after 49.710 days.

Error 708 occurred at disk power-on lifetime: 14869 hours (619 days + 13 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 08 ff ff ff ef 00      15:53:53.672  READ DMA EXT
  27 00 00 00 00 00 e0 00      15:53:53.671  READ NATIVE MAX ADDRESS EXT
  ec 00 00 00 00 00 a0 00      15:53:53.663  IDENTIFY DEVICE
  ef 03 42 00 00 00 a0 00      15:53:53.655  SET FEATURES [Set transfer mode]
  27 00 00 00 00 00 e0 00      15:53:53.655  READ NATIVE MAX ADDRESS EXT

Error 707 occurred at disk power-on lifetime: 14869 hours (619 days + 13 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 08 ff ff ff ef 00      15:53:53.672  READ DMA EXT
  27 00 00 00 00 00 e0 00      15:53:53.671  READ NATIVE MAX ADDRESS EXT
  ec 00 00 00 00 00 a0 00      15:53:53.663  IDENTIFY DEVICE
  ef 03 42 00 00 00 a0 00      15:53:53.655  SET FEATURES [Set transfer mode]
  27 00 00 00 00 00 e0 00      15:53:53.655  READ NATIVE MAX ADDRESS EXT

Error 706 occurred at disk power-on lifetime: 14869 hours (619 days + 13 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 08 ff ff ff ef 00      15:53:50.332  READ DMA EXT
  27 00 00 00 00 00 e0 00      15:53:50.331  READ NATIVE MAX ADDRESS EXT
  ec 00 00 00 00 00 a0 00      15:53:50.323  IDENTIFY DEVICE
  ef 03 42 00 00 00 a0 00      15:53:50.315  SET FEATURES [Set transfer mode]
  27 00 00 00 00 00 e0 00      15:53:50.315  READ NATIVE MAX ADDRESS EXT

Error 705 occurred at disk power-on lifetime: 14869 hours (619 days + 13 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 08 ff ff ff ef 00      15:53:50.332  READ DMA EXT
  27 00 00 00 00 00 e0 00      15:53:50.331  READ NATIVE MAX ADDRESS EXT
  ec 00 00 00 00 00 a0 00      15:53:50.323  IDENTIFY DEVICE
  ef 03 42 00 00 00 a0 00      15:53:50.315  SET FEATURES [Set transfer mode]
  27 00 00 00 00 00 e0 00      15:53:50.315  READ NATIVE MAX ADDRESS EXT

Error 704 occurred at disk power-on lifetime: 14869 hours (619 days + 13 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 08 ff ff ff ef 00      15:53:46.996  READ DMA EXT
  27 00 00 00 00 00 e0 00      15:53:46.995  READ NATIVE MAX ADDRESS EXT
  ec 00 00 00 00 00 a0 00      15:53:46.987  IDENTIFY DEVICE
  ef 03 42 00 00 00 a0 00      15:53:46.980  SET FEATURES [Set transfer mode]
  27 00 00 00 00 00 e0 00      15:53:46.979  READ NATIVE MAX ADDRESS EXT

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]


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.

root@server:~# fsck.ext4 -fpvd /dev/sde1 && fsck.ext4 -cfyvd /dev/sde1

Did only see the end output, ending in:
Error writing block (Attempt to write block from filesystem resulted in short write)
---

root@server:~# dumpe2fs /dev/sde
dumpe2fs 1.41.12 (17-May-2010)
dumpe2fs: Bad magic number in super-block while trying to open /dev/sde
Couldn't find valid filesystem superblock.

root@server:~# fsck.ext4 -fpvd /dev/sde1 && fsck.ext4 -cfyvd /dev/sde1

 291252 inodes used (0.24%)
    3340 non-contiguous files (1.1%)
      16 non-contiguous directories (0.0%)
         # of inodes with ind/dind/tind blocks: 0/0/0
         Extent depth histogram: 290420/822
335634384 blocks used (68.72%)
       0 bad blocks
      38 large files

  276485 regular files
   14758 directories
       0 character device files
       0 block device files
       0 fifos
       0 links
       0 symbolic links (0 fast symbolic links)
       0 sockets
--------
  291243 files
e2fsck 1.41.12 (17-May-2010)
Checking for bad blocks (read-only test): done                                
2TBDisk: Updating bad block inode.
And so on.

root@server:~# fsck.ext4 -fpvd /dev/sde1 && fsck.ext4 -cfyvd /dev/sde1
fsck.ext4: No such file or directory while trying to open /dev/sde1
/dev/sde1:
The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>

root@server:~# e2fsck -b 8193 /dev/sde1 && fsck.ext4 -fpvd /dev/sde1 && fsck.ext4 -cfyvd /dev/sde1
e2fsck 1.41.12 (17-May-2010)
e2fsck: No such file or directory while trying to open /dev/sde1

The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>

root@server:~# fsck.ext4 -b 8193 /dev/sde1
e2fsck 1.41.12 (17-May-2010)
fsck.ext4: No such file or directory while trying to open /dev/sde1

The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>

root@server:~# e2fsck -b 8193 /dev/sde1
e2fsck 1.41.12 (17-May-2010)
e2fsck: No such file or directory while trying to open /dev/sde1

The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck

When the disk was originally used, it would hang at random moments then continue. In the end it ended in read only mode. Later on it would not end in read only mode, but get unmounted and the system would no recognize the device. After a boot it was there again, same problems as first. Now today, it is recognized by the system, but nothing is listed on the file system:

root@server:~# ls /mnt/2TBDisk
ls: reading directory /mnt/2TBDisk: Input/output error
0
Comment
Question by:itnifl
  • 3
  • 3
6 Comments
 
LVL 76

Assisted Solution

by:arnold
arnold earned 500 total points
ID: 40537254
Not sure what it is you are looking for, but based on your comments, the disk died before corrective actions to replace it were taken.

At this stage if the data on the disk is valuable to you, you would need to send it to a data recovery firm for them to attempt to get the data.

If I misinterpreted what you are looking for, please .........
0
 
LVL 2

Author Comment

by:itnifl
ID: 40537262
Hello Arnold and thank you for your comment. You are right in your interpretations. I have backup of some of the files on disk luckily, but I value your perspective of this outpout. All comments are welcome.

I found by chance now that my disk and partition now is /dev/sdg1 instead of /dev/sde1.

#blkid /dev/sdg1
/dev/sdg1: LABEL="2TBDisk" UUID="cd125c54-4881-4395-81f7-c988508a8057" TYPE="ext4"

/etc/fstab says:

/dev/sde1       /mnt/2TBDisk    ext4    defaults,rw     0       0

It is a wonder that anything named /dev/sde1 gout mounted.

root@server:# fdisk -l | grep sd1
root@server:#

I guess I should mount using the UUID. I will try to rescue as much data from the disk as possible, then reformat the disk and rescan. See what happens. Will be posting the results :)
0
 
LVL 76

Assisted Solution

by:arnold
arnold earned 500 total points
ID: 40537270
If the disk is still accessible, and if you have a spare slot as well as a spare drive, cloning it would possibly secure  the data.

Did you connect a new drive such that it displace the prior?

In future implementation using a RAID configuration (mdadm) may help mitigate these types of situations at a sacrifice of a drive which are declining in price.
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 76

Accepted Solution

by:
arnold earned 500 total points
ID: 40537271
You could still get the existing and setup a redundancy that will maintain data on two drives in a mirror configuration.
0
 
LVL 2

Author Comment

by:itnifl
ID: 40543023
I have an onboard RAID controller that I will use for future setup. I have managed to copy some data from the disk that I did not have backup of, but far from all of it. It is now still detected by the system on boot and by the OS, but as soon as I try to read from it or scan it with fsck, the process just hangs and in the end the disk is no longer shown as available by the OS or fdisk -l. I was thinking of trying to change the cables before I give up totally. Maybe try out these suggestions:
http://www.wikihow.com/Recover-a-Dead-Hard-Disk
http://www.geekyprojects.com/storage/how-to-recover-data-from-a-broken-hard-drive/
0
 
LVL 2

Author Comment

by:itnifl
ID: 40554862
Turns out that the disk that failed is a Seagate Barracuda, that pcworld has stated as oner of the worst in theyr test:

http://www.pcworld.com/article/2089464/three-year-27-000-drive-study-reveals-the-most-reliable-hard-drive-makers.html
The worst of the bunch, meanwhile was the 1.5 TB Seagate Barracuda Green (ST1500DL003), with an average lifespan of 0.8 years. Ouch!

I will just toss it, and go for two Western Digital or Hitachi disks instead.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Storage devices are generally used to save the data or sometime transfer the data from one computer system to another system. However, sometimes user accidentally erased their important data from the Storage devices. Users have to know how data reco…
Create your own, high-performance VM backup appliance by installing NAKIVO Backup & Replication directly onto a Synology NAS!
To efficiently enable the rotation of USB drives for backups, storage pools need to be created. This way no matter which USB drive is installed, the backups will successfully write without any administrative intervention. Multiple USB devices need t…
This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now