From: Neil Brown <neilb@suse.de>
To: Chris Webb <chris@arachsys.com>
Cc: Peter Rabbitson <rabbit+list@rabbit.us>, linux-raid@vger.kernel.org
Subject: Re: Trouble increasing md component size
Date: Thu, 19 Jun 2008 13:42:01 +1000 [thread overview]
Message-ID: <18521.54665.166875.489547@notabene.brown> (raw)
In-Reply-To: message from Chris Webb on Wednesday June 18
On Wednesday June 18, chris@arachsys.com wrote:
> Peter Rabbitson <rabbit+list@rabbit.us> writes:
>
> > I had exactly the same problem some months ago. The key is in the
> > (obscure) assembly option --update=devicesize. Find it in the mdadm
> > manpage and the whole picture will come together instantly. The wisdom is
> > not very widespread as this affects only V1.1 and 1.2 superblocks.
>
> Thanks, that's great. I've been using a man page slightly older (2.5.6) than
> the mdadm binary I'm using (2.6.7), which doesn't mention update=devicesize,
> although I'd probably have missed it anyway!
>
> However, is there a way to do this without stopping the array first? I'm
> using it as an LVM PV and slicing it up into logical volumes which clients
> will be running off while I'm wanting to grow it.
Not currently, no.
It would require changing the 'size' as known by md of each device
first. i.e. /sys/block/mdX/md/dev-*/size.
However this currently cannot be changed while the array is active.
I cannot immediately see a good reason why not. It may be as simple
as removing
if (my_mddev->pers)
return -EBUSY;
from the start of rdev_size_store, but I wouldn't recommend
experimenting with that on a production system....
Then you would need some code to update the device sizes to match
their real size (but only if the metadata is at the start of the
device .. or maybe relocating the metadata first ...)
Then you could "--grow --size=max" happily.
I'd put this on my todo list if it wasn't so long already :-)
(Well, I've put it there anyway, but no promises).
NeilBrown
next prev parent reply other threads:[~2008-06-19 3:42 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-18 18:26 Trouble increasing md component size Chris Webb
2008-06-18 19:22 ` Peter Rabbitson
2008-06-18 20:00 ` Chris Webb
2008-06-19 3:42 ` Neil Brown [this message]
2008-06-19 15:45 ` Chris Webb
2008-06-19 23:10 ` Chris Webb
2008-06-19 23:49 ` Chris Webb
2008-06-20 11:13 ` Chris Webb
2008-06-20 14:24 ` Chris Webb
2008-06-23 1:26 ` Neil Brown
2008-06-23 11:18 ` Chris Webb
2008-06-23 22:53 ` Neil Brown
2008-06-24 11:47 ` Chris Webb
2008-06-24 23:19 ` Chris Webb
2008-09-17 18:11 ` [PATCH] md: Fix rdev_size_store with size = 0 Chris Webb
2008-10-07 12:40 ` [Resend] " Chris Webb
2008-10-13 0:54 ` Neil Brown
2008-06-24 2:40 ` Trouble increasing md component size Neil Brown
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=18521.54665.166875.489547@notabene.brown \
--to=neilb@suse.de \
--cc=chris@arachsys.com \
--cc=linux-raid@vger.kernel.org \
--cc=rabbit+list@rabbit.us \
/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).