I have a similar setup to the one you describe, however for the RAID
partitions ID I'm using fd , you set this using fdisk, it's intended for
RAID partitions and the HOWTO suggests using it , in addition to
persistent superblock so the partition gets noticed at boot time.
I haven't had any problems using swap as RAID1, but that's not to say
there won't be any. You probably want to put the drives on separate
controllers, ie, one drive on one IDE and the other on the alternate IDE
controller to further reduce the risk of loosing your system, after all,
your mother board probably has 2 ide controllers.
Just a note, I see you've configured swap as 128Meg, I thought that was
the maximum but I tried configuring a swap partition of 1 Gig and it looks
like it took, I don't know for sure. If I cat /proc/meminfo or run free
or top, the 1 Gig is shown, anyone know if the old limitation of 128 Meg
has been removed and what the new limit is?
On Tue, 23 Nov 1999, David Cunningham wrote:
> The issue is RAID-1 swap. I'm a little unclear as to which method to use to
> ensure best availability for my server. Currently I have two 10 gig EIDE
> drives with identical partitions set up as follows:
>
> Disk /dev/hdb: 16 heads, 63 sectors, 19870 cylinders
> Units = cylinders of 1008 * 512 bytes
>
> Device Boot Start End Blocks Id System
> /dev/hdb1 * 1 21 10552+ 83 Linux
> /dev/hdb2 22 19870 10003896 5 Extended
> /dev/hdb5 22 282 131512+ 82 Linux swap
> /dev/hdb6 283 19870 9872320+ 83 Linux
>
> (Same for drive hdc)
>
> The idea is to make the swap on both drives mirrors of each other so that my
> system won't go down in the event one drive fails. First of all, will this
> work? If so is there anything special I need to configure in the
> /etc/raidtab file to accomodate swap as opposed to ext2.
>
> If this won't work is there a suggested way to ensure my server won't go
> down if a drive dies? I'm assuming the only real problem to address here is
> swap.
>
> In case you're interested here's some other tidbits from my filesystems:
>
> [root@holland /]# cat /proc/mdstat
> Personalities : [raid1]
> read_ahead 1024 sectors
> md3 : active raid1 hdc6[1] hdb6[0] 9872256 blocks [2/2] [UU]
> md1 : active raid1 hdc5[1] hdb5[0] 131392 blocks [2/2] [UU]
> md0 : active raid1 hdc1[1] hdb1[0] 10432 blocks [2/2] [UU]
> unused devices: <none>
>
> [root@holland /]# cat /etc/raidtab
> raiddev /dev/md0
> raid-level 1
> nr-raid-disks 2
> nr-spare-disks 0
> chunk-size 4
> persistent-superblock 1
> device /dev/hdb1
> raid-disk 0
> device /dev/hdc1
> raid-disk 1
>
> raiddev /dev/md1
> raid-level 1
> nr-raid-disks 2
> nr-spare-disks 0
> chunk-size 4 # <------------- Intended for
> swap
> persistent-superblock 1
> device /dev/hdb5
> raid-disk 0
> device /dev/hdc5
> raid-disk 1
>
> raiddev /dev/md3
> raid-level 1
> nr-raid-disks 2
> nr-spare-disks 0
> chunk-size 4
> persistent-superblock 1
> device /dev/hdb6
> raid-disk 0
> device /dev/hdc6
> raid-disk 1
>
---
mailto:[EMAIL PROTECTED]