Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

This is what I pulled:

mdadm --monitor --scan -f --pid-file=/var/run/mdadm/mdadm.pid

 cat /proc/mdstat
Personalities : [raid1]
md0 : active raid1 sda1[0] sdb1[1]
      262080 blocks super 1.0 [2/2] [UU]

md1 : active raid1 sdb2[1] sda2[0]
      8187840 blocks super 1.1 [2/2] [UU]

md2 : active raid1 sdb3[1] sda3[0]
      479800128 blocks super 1.1 [2/2] [UU]
      bitmap: 3/4 pages [12KB], 65536KB chunk

unused devices: <none>

 fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00075973

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          33      262144   fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sda2              33        1053     8192000   fd  Linux raid autodetect
/dev/sda3            1053       60802   479931392   fd  Linux raid autodetect

Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00038574

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1          33      262144   fd  Linux raid autodetect
Partition 1 does not end on cylinder boundary.
/dev/sdb2              33        1053     8192000   fd  Linux raid autodetect
/dev/sdb3            1053       60802   479931392   fd  Linux raid autodetect

Disk /dev/md2: 491.3 GB, 491315331072 bytes
2 heads, 4 sectors/track, 119950032 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000


Disk /dev/md1: 8384 MB, 8384348160 bytes
2 heads, 4 sectors/track, 2046960 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000


Disk /dev/md0: 268 MB, 268369920 bytes
2 heads, 4 sectors/track, 65520 cylinders
Units = cylinders of 8 * 512 = 4096 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x00000000

I am correctly to believe that all the partitions are correctly being mirrored right? Is there a way to check each individual drive to ensure?

share|improve this question

1 Answer 1

The 2 methods I use to determine a RAID's health are as follows.

/proc/mdstat

$ cat /proc/mdstat
Personalities : [raid1] 
md0 : active raid1 sdb1[1] sda1[0]
      976759936 blocks [2/2] [UU]

mdadm --detail

$ mdadm --detail /dev/md0
/dev/md0:
        Version : 0.90
  Creation Time : Sat Jan 26 09:14:11 2008
     Raid Level : raid1
     Array Size : 976759936 (931.51 GiB 1000.20 GB)
  Used Dev Size : 976759936 (931.51 GiB 1000.20 GB)
   Raid Devices : 2
  Total Devices : 2
Preferred Minor : 0
    Persistence : Superblock is persistent

    Update Time : Mon May 26 13:05:25 2014
          State : clean
 Active Devices : 2
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 0

           UUID : 37a3bfcb:41393031:23c133e6:3b879f08
         Events : 0.2182840

    Number   Major   Minor   RaidDevice State
       0       8        1        0      active sync   /dev/sda1
       1       8       17        1      active sync   /dev/sdb1

If there are any issues with your RAID these commands will show that the RAID is not in good health and which members (drives) are failing or have failed.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.