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 06-22-2018, 12:25 PM   #1
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Rep: Reputation: Disabled
Problems mounting partition from a Linux-Raid array (RAID 1) using mdadm


I have a four year old Seagate BlackArmor NAS 220 with two 2TB drives in is configured in RAID 1. Last week, the hardware (chassis) failed and the device will not boot. I have removed one of the drives and attached it to an Ubuntu image via USB.

Disk /dev/sdb: 1.8 TiB, 2000398934016 bytes, 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
Disklabel type: gpt
Disk identifier: D4D0B1A2-AE2B-402A-AE16-8577133024A9

Device Start End Sectors Size Type
/dev/sdb1 195312 2283203 2087892 1019.5M Linux RAID
/dev/sdb2 2283204 4373046 2089843 1020.4M Linux RAID
/dev/sdb3 4373047 5416015 1042969 509.3M Linux RAID
/dev/sdb4 5416016 3906832031 3901416016 1.8T Linux RAID

All of my data is on /dev/sdb4.

$ sudo mdadm --examine /dev/sdb4
/dev/sdb4:
Magic : a92b4efc
Version : 1.2
Feature Map : 0x0
Array UUID : b4e94ab2:ab9780a8:248eedb9:5188f365
Name : 3
Creation Time : Sun Dec 21 14:44:37 2014
Raid Level : raid1
Raid Devices : 2

Avail Dev Size : 3901415744 (1860.34 GiB 1997.52 GB)
Array Size : 1950707840 (1860.34 GiB 1997.52 GB)
Used Dev Size : 3901415680 (1860.34 GiB 1997.52 GB)
Data Offset : 272 sectors
Super Offset : 8 sectors
Unused Space : before=192 sectors, after=64 sectors
State : active
Device UUID : 407169a3:a8cb27ed:7c8e9e1d:aa715c3e

Update Time : Sun Apr 8 20:01:25 2018
Checksum : 90dd0e2b - correct
Events : 93


Device Role : Active device 0
Array State : AA ('A' == active, '.' == missing, 'R' == replacing)


I can start the RAID Array:

$ sudo mdadm -A -R /dev/md9 /dev/sdb4
mdadm: /dev/md9 has been started with 1 drive (out of 2).

But when I try to mount it, I get an error:

$ sudo mount /dev/md9 /mnt/old_hdd/
mount: unknown filesystem type 'LVM2_member'

I have no idea where to go from here. If I can get it mounted, I have another drive to export everything to, and then I can wipe and dispose of the NAS.

What should I try next to get the array mounted?
 
Old 06-22-2018, 01:20 PM   #2
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
Assuming you have "assembled" it, you may need to specify the filesystem to the mount command:

eg.

Code:
mount -t <name of filesystem here> /dev/md9 /mnt/old_hdd/
 
Old 06-22-2018, 01:33 PM   #3
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
I have tried to mount with a forced file system two different ways; ext4 and xfs (recommendations from extensive Googling)

$ sudo mount -t ext4 /dev/md9 /mnt/old_hdd
mount: wrong fs type, bad option, bad superblock on /dev/md9,
missing codepage or helper program, or other error

In some cases useful info is found in syslog - try
dmesg | tail or so.

$ sudo mount -t xfs /dev/md9 /mnt/old_hdd
mount: wrong fs type, bad option, bad superblock on /dev/md9,
missing codepage or helper program, or other error

In some cases useful info is found in syslog - try
dmesg | tail or so.

$ sudo dmesg | tail
[ 3913.366248] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 4094.461737] XFS (md9): Invalid superblock magic number
[ 6800.486427] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 6802.651663] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 6824.434347] XFS (md9): Invalid superblock magic number
 
Old 06-22-2018, 01:50 PM   #4
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
Do you know which filesystem it was formatted with?

You can run the command below, which might give you an idea of which one it is:

Code:
lsblk -f
Post the output from the above command if you're not sure - but use CODE tags if you do.
 
Old 06-22-2018, 01:52 PM   #5
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
All it shows is "linux-raid-member"

Code:
$ lsblk -f
NAME    FSTYPE           LABEL UUID                                   MOUNTPOINT
sdb                                                                   
├─sdb4  linux_raid_membe 3     b4e94ab2-ab97-80a8-248e-edb95188f365   
│ └─md9 LVM2_member            usK4ce-U2Ki-pROZ-HZRS-pcqM-d1ub-enII7i 
├─sdb2  linux_raid_membe       b042c0f8-7b93-2f0b-b943-c34a201ccc7d   
├─sdb3  linux_raid_membe       8f556845-7311-d329-c732-9e3af97d7543   
└─sdb1  linux_raid_membe       d2d80e7f-682a-658c-2161-cd3196d7b9ea   
sr0                                                                   
sda                                                                   
├─sda2                                                                
├─sda5  swap                   acb1c1e3-f28a-4926-b9b4-7491d179e8cc   [SWAP]
└─sda1  ext4                   ca7decda-cc67-4680-bb3d-629aeef404dd   /

Last edited by mcpope; 06-22-2018 at 01:54 PM.
 
Old 06-22-2018, 01:57 PM   #6
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
See if the following one tells you:

Code:
sudo parted -l
 
Old 06-22-2018, 02:00 PM   #7
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
well that's annoying...

Code:
$ sudo parted -l
Model: VMware, VMware Virtual S (scsi)
Disk /dev/sda: 21.5GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start   End     Size    Type      File system     Flags
 1      1049kB  20.4GB  20.4GB  primary   ext4            boot
 2      20.4GB  21.5GB  1072MB  extended
 5      20.4GB  21.5GB  1072MB  logical   linux-swap(v1)


Model: ST2000DL 003-9VT166 (scsi)
Disk /dev/sdb: 2000GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system     Name     Flags
 1      100MB   1169MB  1069MB  ext3                     raid
 2      1169MB  2239MB  1070MB  linux-swap(v1)           raid
 3      2239MB  2773MB  534MB   ext3                     raid
 4      2773MB  2000GB  1998GB                  primary  raid


Error: /dev/md9: unrecognised disk label
Model: Linux Software RAID Array (md)                                     
Disk /dev/md9: 1998GB
Sector size (logical/physical): 512B/512B
Partition Table: unknown
Disk Flags:
 
Old 06-22-2018, 02:02 PM   #8
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
Try this to mount it:

Code:
sudo mount -t ext3 /dev/md9 /mnt/old_hdd/
 
Old 06-22-2018, 02:04 PM   #9
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
So I typed ext3, but the dmesg log says "Can't find ext4 filesystem"

Code:
~$ sudo mount -t ext3 /dev/md9 /mnt/old_hdd/
mount: wrong fs type, bad option, bad superblock on /dev/md9,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

$ dmesg | tail

[ 8751.392090] EXT4-fs (md9): VFS: Can't find ext4 filesystem
 
Old 06-22-2018, 02:13 PM   #10
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
The only other things I can suggest is to:

1) Try re-assembling the RAID;

Code:
mdadm --assemble --run /dev/md9 /dev/sdb4
2) Failing that; try every filesystem listed in the man page for the mount command:

Code:
man mount
The command above will bring up the manual page for the mount command - look under "-t, --types vfstype" for a list of supported filesystems.
 
Old 06-22-2018, 02:15 PM   #11
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
Busy? Is that good or bad?

Code:
$ sudo mdadm --assemble --run /dev/md9 /dev/sdb4
mdadm: /dev/sdb4 is busy - skipping
 
Old 06-22-2018, 02:21 PM   #12
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
It looks like you may need to stop it and then try re-assembling it. Try that and then what I said above.

Code:
sudo umount /dev/md9
Failing the above or if the above gives no error;

Code:
sudo mdadm --stop /dev/md9
Then try re-assembling it as above in my last post.
 
Old 06-22-2018, 02:26 PM   #13
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
Successfully stopped and re-assembled, but it still wouldn't mount as ext3, ext4, or xfs. I will go through and try all the other filesystem types now.

Code:
$ sudo umount /dev/md9
umount: /dev/md9: not mounted
$ sudo mdadm --stop /dev/md9
mdadm: stopped /dev/md9
$ sudo mdadm --assemble --run /dev/md9 /dev/sdb4
mdadm: /dev/md9 has been started with 1 drive (out of 2).

$ sudo mount -t ext3 /dev/md9 /mnt/old_hdd/
mount: wrong fs type, bad option, bad superblock on /dev/md9,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

$ sudo mount -t ext4 /dev/md9 /mnt/old_hdd/
mount: wrong fs type, bad option, bad superblock on /dev/md9,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

$ sudo mount -t xfs /dev/md9 /mnt/old_hdd/
mount: wrong fs type, bad option, bad superblock on /dev/md9,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

$ sudo dmesg | tail
[ 8751.392090] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 9906.052220] md9: detected capacity change from 1997524828160 to 0
[ 9906.052228] md: md9 stopped.
[ 9912.710325] md: md9 stopped.
[ 9912.816448] md/raid1:md9: active with 1 out of 2 mirrors
[ 9912.816476] md9: detected capacity change from 0 to 1997524828160
[ 9940.310512] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 9944.723269] EXT4-fs (md9): VFS: Can't find ext4 filesystem
[ 9950.432693] XFS (md9): Invalid superblock magic number
 
Old 06-22-2018, 02:28 PM   #14
jsbjsb001
Senior Member
 
Registered: Mar 2009
Location: Earth, unfortunately...
Distribution: Currently: OpenMandriva. Previously: openSUSE, PCLinuxOS, CentOS, among others over the years.
Posts: 3,881

Rep: Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063Reputation: 2063
What does the following command tell us now:

Code:
lsblk -f
Post it as before.
 
Old 06-22-2018, 02:30 PM   #15
mcpope
LQ Newbie
 
Registered: Jun 2018
Posts: 16

Original Poster
Rep: Reputation: Disabled
Appears to be the same as before.

Code:
lsblk -f
NAME    FSTYPE            LABEL UUID                                   MOUNTPOINT
sdb                                                                    
├─sdb4  linux_raid_member 3     b4e94ab2-ab97-80a8-248e-edb95188f365   
│ └─md9 LVM2_member             usK4ce-U2Ki-pROZ-HZRS-pcqM-d1ub-enII7i 
├─sdb2  linux_raid_member       b042c0f8-7b93-2f0b-b943-c34a201ccc7d   
├─sdb3  linux_raid_member       8f556845-7311-d329-c732-9e3af97d7543   
└─sdb1  linux_raid_member       d2d80e7f-682a-658c-2161-cd3196d7b9ea   
sr0                                                                    
sda                                                                    
├─sda2                                                                 
├─sda5  swap                    acb1c1e3-f28a-4926-b9b4-7491d179e8cc   [SWAP]
└─sda1  ext4                    ca7decda-cc67-4680-bb3d-629aeef404dd   /
 
  


Reply



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
Can't rebuild a linux RAID array after replacing disk, “mdadm: Cannot open /dev/sdb1: linuxthefish Linux - Server 3 02-25-2015 06:58 AM
LXer: How to create a software RAID-1 array with mdadm on Linux LXer Syndicated Linux News 0 09-16-2014 07:30 AM
[SOLVED] mounting a partition in raid 0 array Cyrolancer Linux - General 3 12-16-2012 03:04 AM
[SOLVED] mdadm: only give one device per ARRAY line: /dev/md/:raid and array laughing_man77 Linux - Hardware 4 03-23-2012 04:05 PM
NTFS Partition Problems on HW Raid 5 Array Absolute Zero Linux - Hardware 5 05-17-2009 10:10 PM

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

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