Software RAID


 
Thread Tools Search this Thread
Special Forums Hardware Filesystems, Disks and Memory Software RAID
# 1  
Old 12-07-2009
Software RAID

Hello,

My company has inherited a Centos based machine that has 7 hard drives and a software based raid system. Supposedly one of the drives has failed. I need to replace the hardrive.

How can I about telling which hard drive needs replacing? I have looked in the logs and there clearly is a problem there is no way I can tell which physical drive seems to have a problem. Advice?
# 2  
Old 12-07-2009
Linux software RAID is usually managed through the mdadm tool. To see the status of the drives enter (replace /dev/md0 with the path to your actual RAID)
Code:
mdadm --detail /dev/md0

# 3  
Old 12-07-2009
How do I know path to actual raid?

How do I find out the path to the actual raid?

Al I see is this:

Code:
[root@drill proc]# df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                      16790968   2805884  13118372  18% /
/dev/hda1               101086     17720     78147  19% /boot
tmpfs                   777728         0    777728   0% /dev/shm
/dev/md0             475751440 389860552  61724084  87% /ha0

When I execute your command I get:

Code:
[root@drill proc]# mdadm --detail /dev/ha0
mdadm: cannot open /dev/ha0: No such file or directory
[root@drill proc]# mdadm --detail /dev/md0
/dev/md0:
        Version : 00.90.03
  Creation Time : Thu Mar 26 19:20:00 2009
     Raid Level : raid1
     Array Size : 483336128 (460.95 GiB 494.94 GB)
  Used Dev Size : 483336128 (460.95 GiB 494.94 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 0
    Persistence : Superblock is persistent

    Update Time : Sun Dec  6 04:07:03 2009
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 4a9f08c9:339514a7:b9ef28ff:12bbcfdb
         Events : 0.6

    Number   Major   Minor   RaidDevice State
       0     253        2        0      active sync   /dev/VolGroup_a/Logical_a
       1     253        3        1      active sync   /dev/VolGroup_b/Logical_b

# 4  
Old 12-07-2009
Quote:
Originally Posted by mojoman
Code:
[root@drill proc]# mdadm --detail /dev/ha0
mdadm: cannot open /dev/ha0: No such file or directory
[root@drill proc]# mdadm --detail /dev/md0
/dev/md0:
        Version : 00.90.03
  Creation Time : Thu Mar 26 19:20:00 2009
     Raid Level : raid1
     Array Size : 483336128 (460.95 GiB 494.94 GB)
  Used Dev Size : 483336128 (460.95 GiB 494.94 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 0
    Persistence : Superblock is persistent

    Update Time : Sun Dec  6 04:07:03 2009
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 4a9f08c9:339514a7:b9ef28ff:12bbcfdb
         Events : 0.6

    Number   Major   Minor   RaidDevice State
       0     253        2        0      active sync   /dev/VolGroup_a/Logical_a
       1     253        3        1      active sync   /dev/VolGroup_b/Logical_b

In your case, /dev/md0 is the software RAID device. It's a RAID1 without any errors, using 2 devices, neither of them degraded or with errors. But none of the 2 is a physical device, but they are logical devices inside LVM volume groups. Which physical devices belong to it you'll see by checking the output of vgdisplay.

From my point of view, it's been set up exactly the wrong way around. If a device fails, you'll have to rescue the volume group and logical devices before you'll be able to rescue the RAID. Also, any data not in the RAID will probably be lost, or at least will have to be restored from backup.

Usually, you create a RAID (in hard- or software), on top of which you create logical devices. That way, if a drive fails it's easy to replace, and the LVM won't even notice a part of it went missing for a while.
# 5  
Old 12-07-2009
I do not see which physical groups they belong to after I run vgdisplay:

Code:
  --- Volume group ---
  VG Name               VolGroup00
  System ID             
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               18.53 GB
  PE Size               32.00 MB
  Total PE              593
  Alloc PE / Size       593 / 18.53 GB
  Free  PE / Size       0 / 0   
  VG UUID               w7Ta2Z-Dx90-jg8v-28ZS-XT2x-zal6-Z7q3r1
   
  --- Volume group ---
  VG Name               VolGroup_a
  System ID             
  Format                lvm2
  Metadata Areas        3
  Metadata Sequence No  6
  VG Access             read/write
  VG Status             resizable
  MAX LV                256
  Cur LV                1
  Open LV               1
  Max PV                256
  Cur PV                3
  Act PV                3
  VG Size               460.95 GB
  PE Size               4.00 MB
  Total PE              118004
  Alloc PE / Size       118004 / 460.95 GB
  Free  PE / Size       0 / 0   
  VG UUID               ql9Zv1-wqXJ-4lPb-mmsM-lyaf-Bj10-rJGU1s
   
  --- Volume group ---
  VG Name               VolGroup_b
  System ID             
  Format                lvm2
  Metadata Areas        3
  Metadata Sequence No  6
  VG Access             read/write
  VG Status             resizable
  MAX LV                256
  Cur LV                1
  Open LV               1
  Max PV                256
  Cur PV                3
  Act PV                3
  VG Size               460.95 GB
  PE Size               4.00 MB
  Total PE              118002
  Alloc PE / Size       118002 / 460.95 GB
  Free  PE / Size       0 / 0   
  VG UUID               RcIQpm-krvC-i3LD-eDQs-00Zy-mHoj-KChH9D

# 6  
Old 12-07-2009
You can get more details about a volume group using
Code:
vgdisplay VolGroup_a
vgdisplay VolGroup_b

Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Solaris

Software RAID on top of Hardware RAID

Server Model: T5120 with 146G x4 disks. OS: Solaris 10 - installed on c1t0d0. Plan to use software raid (veritas volume mgr) on c1t2d0 disk. After format and label the disk, still not able to detect using vxdiskadm. Question: Should I remove the hardware raid on c1t2d0 first? My... (4 Replies)
Discussion started by: KhawHL
4 Replies

2. Red Hat

Software RAID configuration

We have configured software based RAID5 with LVM on our RHEL5 servers. Please let us know if its good to configure software RAID on live environment servers. What can be the disadvantages of software RAID against hardware RAID (4 Replies)
Discussion started by: mitchnelson
4 Replies

3. UNIX for Dummies Questions & Answers

RAID software vs hardware RAID

Hi Can someone tell me what are the differences between software and hardware raid ? thx for help. (2 Replies)
Discussion started by: presul
2 Replies

4. Red Hat

Software RAID doubt

hi friends, I am having issues with adding a spare device to a failed array. I have created RAID 1 with 3 partitions using mdadm command. Later I added a spare with mdadm --add /dev/md0 /dev/sdb6 This works fine and when I check this with mdadm --detail command it just sits there as a spare... (7 Replies)
Discussion started by: saagar
7 Replies

5. Linux

Software RAID on Linux

Hey, I have worked with Linux for some time, but have not gotten into the specifics of hard drive tuning or software RAID. This is about to change. I have a Dell PowerEdge T105 at home and I am purchasing the following: 1GBx4 DDR2 ECC PC6400 RAM Rosewill RSV-5 E-Sata 5 bay disk enclosure... (6 Replies)
Discussion started by: mark54g
6 Replies

6. HP-UX

Software RAID (0+1)

Hi! A couple of months ago a disk failed in our JBOD cabinett and I have finally got a new disk to replace it with. It was a RAID 0 so we have to create and configure the whole thing again. First we thought of RAID 1+0 but it seems you can't do this with LVM. If you read my last thread, you can... (0 Replies)
Discussion started by: hoff
0 Replies

7. UNIX for Advanced & Expert Users

Software RAID ...

Hi all, I m just trying using software RAID in RHEL 4, without problem , then i wanna simulate if disk 1 is fail (thereis an bootloader), i plug off my 1st disk. My problems is the second disk cannot boot? just stuck in grub, the computer is hang. Sorry for poor concept in RAID? I use a RAID 1.... (0 Replies)
Discussion started by: blesets
0 Replies

8. SuSE

Raid software besides Veritass

Hello Lunix people, I am looking for Raid software or solution besides Veritas. Veritas has some great software but are way too costly. Does anyone know of good raid software that but NOT Veritas. I need the funcations but not the cost. (7 Replies)
Discussion started by: xtmeisel
7 Replies

9. UNIX for Advanced & Expert Users

Software Raid - changed devices

Good Morning all, I just have a quick question, on some systems I am working with Software Raid Level 0 devices. Yes, I know, this is not a good idea, but it was requested :-( Now, due to a new requirement, I need to add a second internal disk to the system, but with adding the new disk,... (1 Reply)
Discussion started by: malcom
1 Replies
Login or Register to Ask a Question