Unix/Linux Go Back    


Filesystems, Disks and Memory Discuss NAS, SAN, RAID, Robotic Libraries, backup devices, RAM, DRAM, SCSI, IDE, EIDE topics here.

Reconstructing RAID

Filesystems, Disks and Memory


Tags
linux, nas, raid, vgscan, western

Closed    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 09-03-2012   -   Original Discussion by tonyaldr
tonyaldr's Unix or Linux Image
tonyaldr tonyaldr is offline
Registered User
 
Join Date: Sep 2012
Last Activity: 6 September 2012, 12:23 PM EDT
Posts: 4
Thanks: 2
Thanked 0 Times in 0 Posts
Reconstructing RAID

I am trying to reconstruct a failed 4 disk RAID5 Western Digital ShareSpace device using 3 of the 4 disks connected via USB to an Ubuntu 12.04 machine. I get what seems like a successful re-assemble from -


Code:
mdadm --assemble --force /dev/md2 /dev/sde4 /dev/sdf4 /dev/sdg4
mdadm: /dev/md2 has been started with 3 drives (out of 4).
But then when I try to mount, it fails.  I am logged in as root and when I try to troubleshoot with mdadm, I get odd returns such as -
mdadm --examine /dev/md2
mdadm: No md superblock detected on /dev/md2.
Also, the system can't seem to find the volume -
vgscan -v
    Wiping cache of LVM-capable devices
    Wiping internal VG cache
  Reading all physical volumes.  This may take a while...
    Finding all volume groups
  No volume groups found

I read in some other posts that the WD system uses LVM2.  Could that be the issue?  Here is the output from mdadm --detail
mdadm --detail /dev/md2
/dev/md2:
        Version : 0.90
  Creation Time : Mon Oct 19 10:26:15 2009
     Raid Level : raid5
     Array Size : 5854981248 (5583.75 GiB 5995.50 GB)
  Used Dev Size : 1951660416 (1861.25 GiB 1998.50 GB)
   Raid Devices : 4
  Total Devices : 3
Preferred Minor : 2
    Persistence : Superblock is persistent

    Update Time : Sun Sep  2 15:22:50 2012
          State : clean, degraded 
 Active Devices : 3
Working Devices : 3
 Failed Devices : 0
  Spare Devices : 0

         Layout : left-symmetric
     Chunk Size : 64K

           UUID : 4c4952ae:1477d756:234bdad8:bdaa1368
         Events : 0.9246753

    Number   Major   Minor   RaidDevice State
       0       8       84        0      active sync   /dev/sdf4
       1       8       68        1      active sync   /dev/sde4
       2       0        0        2      removed
       3       8      100        3      active sync   /dev/sdg4

Here's the result of the mount attempt-
mount -t auto dev/md2 /mnt/raid
mount: special device dev/md2 does not exist

Appreciate any assistance! Thanx!

Last edited by Neo; 3 Weeks Ago at 09:59 AM..
Sponsored Links
    #2  
Old Unix and Linux 09-03-2012   -   Original Discussion by tonyaldr
Lem's Unix or Linux Image
Lem Lem is offline
Registered User
 
Join Date: Jun 2012
Last Activity: 25 November 2016, 2:46 PM EST
Location: Lombardia, Italy
Posts: 182
Thanks: 5
Thanked 38 Times in 38 Posts
From mdadm man:
Quote:
--examine applies to devices which are components
of an array, while --detail applies to a whole array which is currently active.
So you can --examine /dev/sdf4, for instance, not /dev/md2. And you can --detail /dev/md2, not /dev/sdf4. Linux

Quote:
Also, the system can't seem to find the volume -
vgscan -v
Wait. We were speaking about a raid volume. This is for LVM(2) volumes: completely different things.

Quote:

Code:
mount -t auto dev/md2 /mnt/raid
mount: special device dev/md2 does not exist
Do you run it from the root directory? Otherwise dev/md2 is not /dev/md2.
--
Bye
The Following User Says Thank You to Lem For This Useful Post:
tonyaldr (09-06-2012)
Sponsored Links
    #3  
Old Unix and Linux 09-03-2012   -   Original Discussion by tonyaldr
tonyaldr's Unix or Linux Image
tonyaldr tonyaldr is offline
Registered User
 
Join Date: Sep 2012
Last Activity: 6 September 2012, 12:23 PM EDT
Posts: 4
Thanks: 2
Thanked 0 Times in 0 Posts
That was a great catch! Although I was running it as root , I was NOT running the mount command from the root folder. Now when I run it -

Code:
mount -t auto /dev/md2 /mnt/raid  I get -
mount: you must specify the filesystem type
I tried ext2, ext3 & ext4 but none seem to work.    Any ideas?
mount -t ext3 /dev/md2 /mnt/raid
mount: wrong fs type, bad option, bad superblock on /dev/md2,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

mount -t ext2 /dev/md2 /mnt/raid
mount: wrong fs type, bad option, bad superblock on /dev/md2,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

mount -t ext4 /dev/md2 /mnt/raid
mount: wrong fs type, bad option, bad superblock on /dev/md2,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so

I have been using the instructions from a post in the Western Digital Community forum - 
"http://community.wdc.com/t5/WD-ShareSpace/HOWTO-Sharespace-RAID-5-Data-Recovery/td-p/287736"
The author admits that he's a Linux novice so would not know how to get past my problem, but this is where I got my info regarding the commands I documented.  The output from dmesg | tail is -
[108585.149513] EXT3-fs (md2): error: can't find ext3 filesystem on dev md2.
[108585.161930] EXT4-fs (md2): VFS: Can't find ext4 filesystem
[108585.758247] ISOFS: Unable to identify CD-ROM format.
[108891.442375] EXT3-fs (md2): error: can't find ext3 filesystem on dev md2.
[108903.988734] EXT2-fs (md2): error: can't find an ext2 filesystem on dev md2.
[108915.586612] EXT4-fs (md2): VFS: Can't find ext4 filesystem
[109694.031696] EXT3-fs (md2): error: can't find ext3 filesystem on dev md2.
[109694.047559] EXT4-fs (md2): VFS: Can't find ext4 filesystem
[109694.653264] ISOFS: Unable to identify CD-ROM format.
[109694.671254] EXT2-fs (md2): error: can't find an ext2 filesystem on dev md2.

I have a bad feeling that there's something wrong with the partition tables. Appreciate your help!
    #4  
Old Unix and Linux 09-04-2012   -   Original Discussion by tonyaldr
Lem's Unix or Linux Image
Lem Lem is offline
Registered User
 
Join Date: Jun 2012
Last Activity: 25 November 2016, 2:46 PM EST
Location: Lombardia, Italy
Posts: 182
Thanks: 5
Thanked 38 Times in 38 Posts
From what I've been reading about those ShareSpace devices, there should be an LVM2 volume, indeed, on top of the raid. So you should find it, and then mount it. If things are like that, of course you cannot mount the raid volume itself, because it doesn't have a filesystem on it. But you didn't find the lvm2 volume, when running vgscan, so I don't have good feelings... Linux

Since you've used --force to reassemble the raid (instead of only --run), now the raid is active, but it could nonetheless be corrupted:

(from mdadm manual)
Quote:
-f, --force
Assemble the array even if the metadata on some devices appears to be out-of-date.
If mdadm cannot find enough working devices to start the array, but can find some
devices that are recorded as having failed, then it will mark those devices as
working so that the array can be started. An array which requires --force to be
started may contain data corruption. Use it carefully.

-R, --run
Attempt to start the array even if fewer drives were given than were present last
time the array was active. Normally if not all the expected drives are found and
--scan is not used, then the array will be assembled but not started. With --run
an attempt will be made to start it anyway.
Let's made another attempt, manually inspecting the beginning of /dev/md2:


Code:
# dd if=/dev/md2 bs=512 count=255 skip=1 of=/tmp/md2lvm
# less /tmp/md2lvm

(Better than less, use a text editor of your choice).

Among binary data, do you see some LVM metadata declarations? Can you find the most recent one? Or there's nothing useful?
--
Bye
The Following User Says Thank You to Lem For This Useful Post:
tonyaldr (09-06-2012)
Sponsored Links
    #5  
Old Unix and Linux 09-04-2012   -   Original Discussion by tonyaldr
tonyaldr's Unix or Linux Image
tonyaldr tonyaldr is offline
Registered User
 
Join Date: Sep 2012
Last Activity: 6 September 2012, 12:23 PM EDT
Posts: 4
Thanks: 2
Thanked 0 Times in 0 Posts
Doesn't look good. Here's a copy of what I see -

Code:
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^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@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@

Takes up the whole screen.
Sponsored Links
    #6  
Old Unix and Linux 09-06-2012   -   Original Discussion by tonyaldr
tonyaldr's Unix or Linux Image
tonyaldr tonyaldr is offline
Registered User
 
Join Date: Sep 2012
Last Activity: 6 September 2012, 12:23 PM EDT
Posts: 4
Thanks: 2
Thanked 0 Times in 0 Posts
I guess it's hopeless then. I'll just have to wipe and re-use the disks. Thanx for all your help! Linux
Sponsored Links
    #7  
Old Unix and Linux 09-06-2012   -   Original Discussion by tonyaldr
Lem's Unix or Linux Image
Lem Lem is offline
Registered User
 
Join Date: Jun 2012
Last Activity: 25 November 2016, 2:46 PM EST
Location: Lombardia, Italy
Posts: 182
Thanks: 5
Thanked 38 Times in 38 Posts
Without lvm metadata, I really don't know what could we do.

I'm sorry you didn't find someone more skilled than me. I'm neither a sysadmin nor an expert, actually.
Maybe you want to wait a little more for some help.
--
Bye.
Sponsored Links
Closed

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Software RAID on top of Hardware RAID KhawHL Solaris 4 12-16-2011 02:52 AM
SCSI PCI - X RAID Controller card RAID 5 AIX Disks disappeared filosophizer AIX 0 06-14-2011 03:20 PM
RAID software vs hardware RAID presul UNIX for Dummies Questions & Answers 2 07-20-2010 03:09 PM
reconstructing a record in a diffrent order r1500 UNIX for Dummies Questions & Answers 1 10-16-2003 06:24 PM



All times are GMT -4. The time now is 07:41 AM.