Linux RAID subsystem development
 help / color / mirror / Atom feed
From: Scott McDermott <vaxerdec@frontiernet.net>
To: linux-raid@vger.kernel.org
Subject: Re: Mirroring swap
Date: Thu, 26 Jun 2003 05:46:55 -0400	[thread overview]
Message-ID: <20030626054655.Q9583@newbox.localdomain> (raw)
In-Reply-To: <Pine.LNX.4.44.0306251535120.16603-100000@gpu.utcc>; from dky@utcc.utoronto.ca on Wed, Jun 25, 2003 at 03:39:45PM -0400

Derek Yeung on Wed 25/06 15:39 -0400:
> I was wondering if it's a good idea to also mirror the
> swap partition?  

You should definitely mirror swap or any dirty pages which
are swap-backed will be lost when the swap device dies,
resulting in data or filesystem corruption.  Not to mention
that your system will almost certainly crash when this
occurs.

> I was reading old posts in the newsgroups that suggest
> this may not be a good idea but i can't seem to find an
> answer as to why.

The old RAID code couldn't handle swap for some reason, but
that was fixed a long time ago.  I believe it had something
to do with deadlocking in a situation where the RAID code
needed memory for some dealings with the mirrored swap
device, but the memory couldn't be obtained without swapping
out, which as you can imagine would cause problems.  I think
they changed this by making the kinds of buffers used by
RAID in these situations to be pinned, but I don't know.

> If it's a good idea, can anyone suggest how i can do it?
> (mirror swap?)  I don't currently have it set up yet.

swapoff, mkraid, raidstart, mkswap, swapon, vi /etc/fstab

  parent reply	other threads:[~2003-06-26  9:46 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-06-25 19:39 Mirroring swap Derek Yeung
2003-06-26  7:07 ` Riley Williams
2003-06-26  7:30   ` Matti Aarnio
2003-06-26  8:30   ` Gordon Henderson
2003-06-26 21:23     ` Gregory Leblanc
2003-06-26 21:44       ` Corey McGuire
2003-06-27  1:56         ` Scott McDermott
2003-06-27  2:14           ` Corey McGuire
2003-06-27  2:24             ` Scott McDermott
     [not found]               ` <200306261957360966.057B8F63@ilneval.coreyfro.com>
2003-06-27  3:22                 ` Corey McGuire
2003-06-27 16:17                   ` Ricky Beam
2003-06-27 18:04                     ` Show me the cache, was " Corey McGuire
2003-06-27 18:24                       ` Ricky Beam
2003-06-27 23:31                         ` Corey McGuire
2003-06-27  8:49       ` Gordon Henderson
2003-06-26  9:46 ` Scott McDermott [this message]
  -- strict thread matches above, loose matches on Subject: below --
2003-06-25 19:58 Bailey, Scott

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=20030626054655.Q9583@newbox.localdomain \
    --to=vaxerdec@frontiernet.net \
    --cc=linux-raid@vger.kernel.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