Hello all,

Sorry for such a simple request but I can't seem to get mkraid to work.
I want to mirror (RAID-1) two 4.2 GB SCSI drives (/dev/sda, /dev/sdb).

Distribution: Redhat 5.2 (Linux 2.0.36)
Software....: RAIDTools 0.50 BETA 10

The Multiple Devices Driver Support is enabled in the kernel with all
sub-options enabled as well (linear, RAID-0, RAID-1, RAID-4, and RAID-5).

The two SCSI disks are laid out identically:

Disk /dev/sda: 132 heads, 62 sectors, 1017 cylinders
Units = cylinders of 8184 * 512 bytes

   Device Boot    Start      End   Blocks   Id  System
/dev/sda1             1       26   106361   83  Linux native    # /
/dev/sda2            27       59   135036   82  Linux swap      # swap
/dev/sda3            60     1017  3920136    5  Extended
/dev/sda5            60       92   135005   83  Linux native    # /tmp
/dev/sda6            93      143   208661   83  Linux native    # /var
/dev/sda7           144      331   769265   83  Linux native    # /usr
/dev/sda8           332      582  1027061   83  Linux native    # /opt
/dev/sda9           583     1017  1779989   83  Linux native    # /home

Disk /dev/sdb: 132 heads, 62 sectors, 1017 cylinders
Units = cylinders of 8184 * 512 bytes

   Device Boot    Start      End   Blocks   Id  System
/dev/sdb1             1       26   106361   83  Linux native    # /
/dev/sdb2            27       59   135036   82  Linux swap      # swap
/dev/sdb3            60     1017  3920136    5  Extended
/dev/sdb5            60       92   135005   83  Linux native    # /tmp
/dev/sdb6            93      143   208661   83  Linux native    # /var
/dev/sdb7           144      331   769265   83  Linux native    # /usr
/dev/sdb8           332      582  1027061   83  Linux native    # /opt
/dev/sdb9           583     1017  1779989   83  Linux native    # /home

I want to mirror the following way:

/dev/sda1 => /dev/sdb1
/dev/sda5 => /dev/sdb5
/dev/sda6 => /dev/sdb6
/dev/sda7 => /dev/sdb7
/dev/sda8 => /dev/sdb8
/dev/sda9 => /dev/sdb9

This assumes that /dev/sda2 (swap) and /dev/sda3 (extended partition) do
not need to be mirrored.

Here is the /etc/raidtab I have setup:

-------------------------------- /etc/raidtab -----------------------------
#  raid-1 configuration for /
raiddev                 /dev/md1
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda1
raid-disk               0

device                  /dev/sdb1
raid-disk               1

#  raid-1 configuration for /tmp
raiddev                 /dev/md5
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda5
raid-disk               0

device                  /dev/sdb5
raid-disk               1

# raid-1 configuration for /var
raiddev                 /dev/md6
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda6
raid-disk               0

device                  /dev/sdb6
raid-disk               1

# raid-1 configuration for /usr
raiddev                 /dev/md7
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda7
raid-disk               0

device                  /dev/sdb7
raid-disk               1

# raid-1 configuration for /opt
raiddev                 /dev/md8
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda8
raid-disk               0

device                  /dev/sdb8
raid-disk               1

# raid-1 configuration for /home
raiddev                 /dev/md9
raid-level              1
nr-raid-disks           2
nr-spare-disks          0

device                  /dev/sda9
raid-disk               0

device                  /dev/sdb9
raid-disk               1

---------------------------------------------------------------------------

This is the /etc/mdtab file:

---------------------------------------------------------------------------
/dev/md1        RAID1   /dev/sda1       /dev/sdb1       # /
/dev/md5        RAID1   /dev/sda5       /dev/sdb5       # /tmp
/dev/md6        RAID1   /dev/sda6       /dev/sdb6       # /var
/dev/md7        RAID1   /dev/sda7       /dev/sdb7       # /usr
/dev/md8        RAID1   /dev/sda8       /dev/sdb8       # /opt
/dev/md9        RAID1   /dev/sda9       /dev/sdb9       # /home
---------------------------------------------------------------------------

We used the following command unsuccessfully:

mkraid /etc/raidtab
mkraid -c /etc/raidtab
mkraid
mkraid -f

The response we get from each of these commands is:

Nothing to do.

We have also read through the available documentation (FAQ, HOWTO, manpage,
README, etc) to no avail.  Can someone give us some advice?

Thanks gang,

Paul B. Brown
Principle Operations Support Engi-weenie
PSINet, Inc.
[EMAIL PROTECTED]
703/375-1894 

Reply via email to