public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Jim Burwell <jimb@jsbc.cc>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Software RAID Advice Needed
Date: Fri, 16 Dec 2005 04:05:09 -0800	[thread overview]
Message-ID: <43A2AD75.1010200@jsbc.cc> (raw)
In-Reply-To: <19511.1134727583@www18.gmx.net>

[-- Attachment #1: Type: text/plain, Size: 3306 bytes --]

jarry@gmx.net wrote:

>>>If a disk fails,
>>>your system would likely crash (due to the swap device), but would
>>>reboot in a degraded mode (no swap, slow performance, etc).
>>>      
>>>
>>You could avoid that by not using RAID for swap. Instead, use four
>>separate swap partitions, one on each drive. As long as they all have
>>the same priority, the kernel will share swap duties between them
>>equally.
>>    
>>
> 
>If you make more swap partitions on more physical drives with the same
>priority, it is the same as swap on raid0: system strips swap across
>drives. And if some drive crashes and swap partition on that drive has
>been used, very probably system crashes too. But then reboots at least
>with remaining swap partitions...
>  
>

Yes, although there's a posibility of an 'endless crash/reboot' scenereo 
here, if the errors are 'soft' (e.g. not drive just vanishing).  For 
instance, a few bad sectors develop on one of your swap partitions, the 
kernel can't read them, and panic/reboots.  The system comes back up, 
the same swaps are used, and it happens again, over and over until you 
edit the bad partition out of the fstab.

In a redundant RAID situation, I'm presuming that a bad sector or two 
would result in the RAID driver detaching the bad drive, and chugging 
along in degraded mode, where if this happened in a distrubuted swap 
situation, it's already 'too late', since the sectors are lost and the 
kernel would probably panic.

>>There's no real benefit to using RAID for swap, unless you are
>>limited on RAM and use swap a lot, when RAID0 may help.
>>    
>>
>
>There is some benefit, if you use raid1 for swap. In such a case
>even drive failure does not cause system crash, because swap space
>is mirrored too. But raid1 slightly degrades swap performance...
>  
>

This is exactly why I'm doing RAID1 on swap.  If one drive goes poof, my system stays up.  Based on what this server is going to do, it should rarely use much swap, so swap performance isn't a priority for me.  Plus, as you say, I believe the performance hit on swap writes (reads should actually be faster) should wind up being only a bit slower than if you were swapping to a single drive.


- Jim

-- 
+---------------------------------------------------------------------------+
|         Jim Burwell - Sr. Systems/Network/Security Engineer, JSBC         |
+---------------------------------------------------------------------------+
| "I never let my schooling get in the way of my education." - Mark Twain   |
| "UNIX was never designed to keep people from doing stupid things, because |
|  that policy would also keep them from doing clever things." - Doug Gwyn  |
| "Cool is only three letters away from Fool" - Mike Muir, Suicyco          |
| "..Government in its best state is but a necessary evil; in its worst     |
|  state an intolerable one.." - Thomas Paine, "Common Sense" (1776)        |
+---------------------------------------------------------------------------+
|   Email:  jimb@jsbc.cc                              ICQ UIN:  1695089     |
+---------------------------------------------------------------------------+
|  Reply problems ?  Turn off the "sign" function in email prog.  Blame MS. |
+---------------------------------------------------------------------------+


[-- Attachment #2: Type: text/html, Size: 4135 bytes --]

      reply	other threads:[~2005-12-16 12:10 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-15 21:55 [gentoo-user] Software RAID Advice Needed Doug Brown
2005-12-15 22:29 ` Mike Williams
2005-12-15 22:33 ` kashani
2005-12-16  0:49   ` Ognjen Bezanov
2005-12-16  1:25     ` Richard Fish
2005-12-16  2:38       ` Jim Burwell
2005-12-16  1:21   ` Richard Fish
2005-12-16  9:49     ` Neil Bothwick
2005-12-16 10:06       ` jarry
2005-12-16 12:05         ` Jim Burwell [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=43A2AD75.1010200@jsbc.cc \
    --to=jimb@jsbc.cc \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox