linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Doug Ledford <dledford@redhat.com>
To: Leslie Rhorer <lrhorer@satx.rr.com>
Cc: linux-raid@vger.kernel.org
Subject: Re: Bitmap did not survive reboot
Date: Wed, 11 Nov 2009 15:32:21 -0500	[thread overview]
Message-ID: <4AFB1F55.60405@redhat.com> (raw)
In-Reply-To: <20091111033418841.IRLD6968@cdptpa-omta02.mail.rr.com>

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

On 11/10/2009 10:34 PM, Leslie Rhorer wrote:
>>  If the array isn't super performance critical, I would use mdadm
>> to delete the bitmap, then grow an internal bitmap with a nice high
>> chunk size and just go from there.  It can't be worse than what you've
>> got going on now.
> 
> 	I really dislike that option.  Doing it manually every time I boot
> would be a pain.  Writing a script to do it automatically is no more trouble
> (or really much different) than writing a script to mount the partition
> explicitly prior to running mdadm, but it avoids any issues of which I am
> unaware (but can imagine) with, say, trying to grow a bitmap on an array
> that is other than clean.  I'd rather have mdadm take care of such details.

I think you are overestimating the difficulty of this solution.  It's as
simple as:

mdadm -G /dev/md0 --bitmap=none
mdadm -G /dev/md0 --bitmap=internal --bitmap-chunk=32768 (or even higher)

and you are done.  It won't need to resync the entire device as the
device is already clean and it won't create a bitmap that's too large
for the free space that currently exists between the superblock and the
start of your data.  You can see the free space available for a bitmap
by running mdadm -E on one of the block devices and interpreting the
data start/data offset/superblock offset fields (sorry there isn't a
simply field to look at, but the math changes depending on what
superblock version you use and I can't remember if I've ever known what
superblock you happen to have).  No need to copy stuff around, no need
to take things down, all done in place, and the issue is solved
permanently with no need to muck around in your system init scripts as
from now on when you boot up the bitmap is internal to the array and
will be used from the second the array is assembled.  The only reason I
mentioned anything about performance is because an internal bitmap does
slightly slow down random access to an array (although not so much
streaming access), but that slowdown is mitigated by using a nice high
bitmap chunk size (and for most people a big bitmap chunk is preferable
anyway).  As I recall, you are serving video files, so your access
pattern is large streaming I/O, and that means the bitmap really
shouldn't be noticeable in your performance.

-- 
Doug Ledford <dledford@redhat.com>
              GPG KeyID: CFBFF194
	      http://people.redhat.com/dledford

Infiniband specific RPMs available at
	      http://people.redhat.com/dledford/Infiniband


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

  parent reply	other threads:[~2009-11-11 20:32 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <4AF9ABAA.1020407@redhat.com>
2009-11-11  3:34 ` Bitmap did not survive reboot Leslie Rhorer
2009-11-11  3:46   ` Leslie Rhorer
2009-11-11  5:22     ` Majed B.
2009-11-11  8:13       ` Leslie Rhorer
2009-11-11  8:19         ` Michael Evans
2009-11-11  8:53           ` Leslie Rhorer
2009-11-11  9:31             ` John Robinson
2009-11-11 14:52               ` Leslie Rhorer
2009-11-11 16:02                 ` John Robinson
2009-11-11  9:31         ` Majed B.
2009-11-11 14:54           ` Leslie Rhorer
2009-11-11  9:16       ` Robin Hill
2009-11-11 15:01         ` Leslie Rhorer
2009-11-11 15:53           ` Robin Hill
2009-11-11 20:35           ` Doug Ledford
2009-11-11 21:46             ` Ben DJ
2009-11-11 22:10               ` Robin Hill
2009-11-12  1:35               ` Doug Ledford
2009-11-12  0:23             ` Leslie Rhorer
2009-11-12  1:34               ` Doug Ledford
2009-11-12  4:55                 ` Leslie Rhorer
2009-11-12  5:22                   ` Doug Ledford
2009-11-14 21:48                     ` Leslie Rhorer
2009-11-15 11:01                       ` Doug Ledford
2009-11-15 19:27                         ` Leslie Rhorer
2009-11-11 15:19   ` Gabor Gombas
2009-11-11 16:48     ` Leslie Rhorer
2009-11-11 20:32   ` Doug Ledford [this message]
2009-11-10  1:44 Leslie Rhorer
2009-11-10  1:58 ` Leslie Rhorer

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=4AFB1F55.60405@redhat.com \
    --to=dledford@redhat.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=lrhorer@satx.rr.com \
    /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;
as well as URLs for NNTP newsgroup(s).