public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Daniel Frey <djqfrey@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Run command after root mounted ro?
Date: Tue, 09 Aug 2011 12:30:32 -0700	[thread overview]
Message-ID: <4E418AD8.7070707@gmail.com> (raw)

Greetings,

I discovered a possible reason for mdadm always marking my raid array as
bad on reboot. The problem is I don't know how to check for the issue.

When using root on a native mdadm raid, the kernel handles the array
state transition at shutdown, so it's not a big deal. However, it's
different when using external metadata - mdadm must be called before the
reboot.

Apparently mdadm must be called after the root filesystem is mounted
read-only. Then it can mark the array as clean and not rebuild every
single reboot.

Where do I check this? The /etc/init.d/mdadm script happens well before
root is mounted read-only.

Apparently `mdadm --wait-clean --scan` needs to be called so the
external metadata is updated correctly. If you use this command with a
native mdadm raid it does nothing, but it's critical apparently to the
health of other metadata types.

I've grepped through /etc/init.d/ and found nothing.

Dan



             reply	other threads:[~2011-08-09 19:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-09 19:30 Daniel Frey [this message]
2011-08-09 19:50 ` [gentoo-user] Run command after root mounted ro? Florian Philipp
2011-08-10  1:04   ` Daniel Frey
2011-08-10 15:00     ` Florian Philipp

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=4E418AD8.7070707@gmail.com \
    --to=djqfrey@gmail.com \
    --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