Missing RAID array - please help

    • Missing RAID array - please help

      I've got an HP Microserver running an admittedly older version of OMV. There was a power cut in our area yesterday, and when the mains returned and the server fired up it was missing it's main storage array. The missing array is held on 2 x WD Red 3TB disks, and it's a RAID 1 mirror.

      Here is the diagnostic info that was listed in the pinned message about raid issues:

      Display Spoiler

      openmediavault:~$ cat /proc/mdstat
      Personalities :
      md0 : inactive sdb[1](S)
      2930265560 blocks super 1.2

      unused devices: <none>


      openmediavault:~$ sudo blkid
      /dev/sdc1: UUID="7f4de168-00d0-4b79-bbdd-11f68bc77d38" TYPE="ext4"
      /dev/sdc5: UUID="d8afab16-b5df-4a3b-b2e1-58441d71deec" TYPE="swap"
      /dev/sdb: UUID="2d60afa6-bcee-fcde-f5e4-c2f94abe77c3" LABEL="openmediavault:Mirror1" TYPE="linux_raid_member"


      openmediavault:~$ sudo fdisk -l | grep "Disk "

      Unable to read /dev/sda



      openmediavault:~$ cat /etc/mdadm/mdadm.conf
      # mdadm.conf
      #
      # Please refer to mdadm.conf(5) for information about this file.
      #

      # by default, scan all partitions (/proc/partitions) for MD superblocks.
      # alternatively, specify devices to scan, using wildcards if desired.
      # Note, if no DEVICE line is present, then "DEVICE partitions" is assumed.
      # To avoid the auto-assembly of RAID devices a pattern that CAN'T match is
      # used if no RAID devices are configured.
      DEVICE partitions

      # auto-create devices with Debian standard permissions
      CREATE owner=root group=disk mode=0660 auto=yes

      # automatically tag new arrays as belonging to the local system
      HOMEHOST <system>

      # definitions of existing MD arrays
      ARRAY /dev/md0 metadata=1.2 name=openmediavault:Mirror1 UUID=2d60afa6:bceefcde:f5e4c2f9:4abe77c3



      openmediavault:~$ sudo mdadm --detail --scan --verbose
      mdadm: md device /dev/md0 does not appear to be active.


      I also ran a quick badblock check on sda
      Display Spoiler

      openmediavault:~$ sudo badblocks /dev/sda
      0
      4
      5
      6
      7
      ^C

      Interrupted at block 579256


      I guess this means that the sda drive is toast, but I'm hoping that as the volume was a mirror I might be able to get the array back up with sdb only so I can recover the data. Please can anyone tell me what commands I should use to go about that?
    • Check the state of /dev/sda in smart, to get the raid back, from the command line mdadm --assemble --verbose --force /dev/md0/ /dev/sd[ab] it will probably come back as clean/degraded due to the missing drive but worth a shot using both drive references.
      Raid is not a backup! Would you go skydiving without a parachute?
    • I've checked both drives with smartctl, and as far as I can see neither is showing any errors there:

      Display Spoiler

      openmediavault:~$ sudo smartctl --all /dev/sda
      smartctl 5.40 2010-07-12 r3124 [x86_64-unknown-linux-gnu] (local build)
      Copyright (C) 2002-10 by Bruce Allen, smartmontools.sourceforge.net

      === START OF INFORMATION SECTION ===
      Device Model: WDC WD30EFRX-68AX9N0
      Serial Number: WD-WMC1T1164682
      Firmware Version: 80.00A80
      User Capacity: 3,000,592,982,016 bytes
      Device is: Not in smartctl database [for details use: -P showall]
      ATA Version is: 9
      ATA Standard is: Exact ATA specification draft version not indicated
      Local Time is: Thu Nov 7 22:05:37 2019 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: (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: (41940) seconds.
      Offline data collection
      capabilities: (0x7b) SMART execute Offline immediate.
      Auto Offline data collection on/off supp ort.
      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: (0x70bd) SCT Status supported.
      SCT Error Recovery Control 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 199 199 051 Pre-fail Always - 65535
      3 Spin_Up_Time 0x0027 176 167 021 Pre-fail Always - 6183
      4 Start_Stop_Count 0x0032 100 100 000 Old_age Always - 35
      5 Reallocated_Sector_Ct 0x0033 200 200 140 Pre-fail Always - 0
      7 Seek_Error_Rate 0x002e 200 200 000 Old_age Always - 0
      9 Power_On_Hours 0x0032 026 025 000 Old_age Always - 54669
      10 Spin_Retry_Count 0x0032 100 253 000 Old_age Always - 0
      11 Calibration_Retry_Count 0x0032 100 253 000 Old_age Always - 0
      12 Power_Cycle_Count 0x0032 100 100 000 Old_age Always - 35
      192 Power-Off_Retract_Count 0x0032 200 200 000 Old_age Always - 29
      193 Load_Cycle_Count 0x0032 200 200 000 Old_age Always - 5
      194 Temperature_Celsius 0x0022 119 104 000 Old_age Always - 31
      196 Reallocated_Event_Count 0x0032 200 200 000 Old_age Always - 0
      197 Current_Pending_Sector 0x0032 200 200 000 Old_age Always - 0
      198 Offline_Uncorrectable 0x0030 100 253 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 200 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 Extended offline Completed without error 00% 7 -
      # 2 Conveyance offline Completed without error 00% 0 -
      # 3 Short offline Completed without error 00% 0 -

      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.

      (post was too long with smartctl output for both disks included)



      I've tried the commands to assemble the raid, and got the following:

      Display Spoiler

      openmediavault:~$ sudo mdadm --assemble --verbose --force /dev/md0/ /dev/sdb
      mdadm: looking for devices for /dev/md0/
      mdadm: cannot open device /dev/sdb: Device or resource busy
      mdadm: /dev/sdb has no superblock - assembly aborted


      openmediavault:~$ sudo mdadm --assemble --verbose --force /dev/md0/ /dev/sda
      mdadm: looking for devices for /dev/md0/
      mdadm: /dev/md0/ is an invalid name for an md device. Try /dev/md/md0/

      openmediavault:~$ sudo mdadm --assemble --verbose --force /dev/md0/ /dev/sda /dev/sdb
      mdadm: looking for devices for /dev/md0/
      mdadm: cannot open device /dev/sdb: Device or resource busy

      mdadm: /dev/sdb has no superblock - assembly aborted


      Not sure what the output for assembling with sda means... but I'm guessing that sdb might need the raid superblock to be recovered from a backup? Any ideas?
    • Holfernes_66 wrote:

      Any ideas?
      Whilst I forgot the obvious, my bad, I clearly stated mdadm --assemble --verbose --force /dev/md0/ /dev/sd[ab] I did not say to assemble with just one drive, although it would work I needed to see the error!!
      So;
      mdadm --stop /dev/md0 followed by the above.

      Then post the output of the first five from here
      Raid is not a backup! Would you go skydiving without a parachute?
    • Thanks for sticking with me!

      The assemble still didn't work:

      openmediavault:~$ sudo mdadm --stop /dev/md0
      mdadm: stopped /dev/md0
      openmediavault:~$ sudo mdadm --assemble --verbose --force /dev/md0/ /dev/sda /dev/sdb
      mdadm: looking for devices for /dev/md0/
      mdadm: /dev/md0/ is an invalid name for an md device. Try /dev/md/md0/

      Here's the output of the first items from the other thread:

      Display Spoiler

      openmediavault:~$ cat /proc/mdstat
      Personalities :
      unused devices: <none>

      openmediavault:~$ sudo blkid
      /dev/sdc1: UUID="7f4de168-00d0-4b79-bbdd-11f68bc77d38" TYPE="ext4"
      /dev/sdc5: UUID="d8afab16-b5df-4a3b-b2e1-58441d71deec" TYPE="swap"
      /dev/sdb: UUID="2d60afa6-bcee-fcde-f5e4-c2f94abe77c3" LABEL="openmediavault:Mirror1" TYPE="linux_raid_member"

      openmediavault:~$ sudo fdisk -l | grep "Disk "

      Unable to read /dev/sda

      openmediavault:~$ cat /etc/mdadm/mdadm.conf
      # mdadm.conf
      #
      # Please refer to mdadm.conf(5) for information about this file.
      #

      # by default, scan all partitions (/proc/partitions) for MD superblocks.
      # alternatively, specify devices to scan, using wildcards if desired.
      # Note, if no DEVICE line is present, then "DEVICE partitions" is assumed.
      # To avoid the auto-assembly of RAID devices a pattern that CAN'T match is
      # used if no RAID devices are configured.
      DEVICE partitions

      # auto-create devices with Debian standard permissions
      CREATE owner=root group=disk mode=0660 auto=yes

      # automatically tag new arrays as belonging to the local system
      HOMEHOST <system>

      # definitions of existing MD arrays
      ARRAY /dev/md0 metadata=1.2 name=openmediavault:Mirror1 UUID=2d60afa6:bceefcde:f5e4c2f9:4abe77c3

      openmediavault:~$ sudo mdadm --detail --scan --verbose
      openmediavault:~$
    • Holfernes_66 wrote:

      Here's the output of the first items from the other thread:
      I've looked back at your first post and compared it to your latest which is what I needed, put simply the Raids toast, the fdisk output in both is missing information about all the drives.

      Your post 3 attempts to assemble but can't locate /dev/sda and /dev/sdb throws this mdadm: /dev/sdb has no superblock - assembly aborted the superblock is fixable if there is a working drive in an array. Post 5 mdadm --detail --scan --verbose and cat /proc/mdstat return nothing once the raid is stopped.

      You could try booting with a SystemRescueCD and try the commands again as this ignores OMV, and try fsck on each drive may help may not, but ultimately it doesn't look good.

      Can the data be recovered? one way to find out is to mount one drive on another system and see.
      Raid is not a backup! Would you go skydiving without a parachute?