From: Hugo Mills <hugo@carfax.org.uk>
To: Zener <zener78@gmail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: btrfs metadata mirroring
Date: Fri, 27 Nov 2020 16:09:37 +0000 [thread overview]
Message-ID: <20201127160937.GF1908@savella.carfax.org.uk> (raw)
In-Reply-To: <96b1b2e0-40d6-dfa4-25bf-dda02732f30a@gmail.com>
On Fri, Nov 27, 2020 at 04:11:19PM +0100, Zener wrote:
> Hi, I have a disk with btrfs but now I'd like enable just metadata mirroring
> to understand if some error occurs.
> Do I need another disk / partition / volume dedicated?
> How to do?
> Is it safe now or do I risk to loss my formely data?
It's quite possible that you already have it.
If you look at the output of "btrfs fi usage -T /mountpoint",
you'll see the RAID level for your metadata listed. If it's "DUP",
then you have two copies of each metadata block duplicated --
effectively running "RAID-1" for your metadata, but on a single
device.
If it says "single", then you've only got one copy of your
metadata. You can convert it to DUP with a balance conversion:
# btrfs balance start -mconvert=dup,soft /mountpoint
You may need to run this more than once. Sometimes the conversion
process manages to allocate (and then skip over) a new metadata chunk
as single. Check with "btrfs fi usage -T /mountpoint" after running
the first time, and see if there's any single metadata allocation
left. If there is, run the command again.
Hugo.
--
Hugo Mills | Anyone who says their system is completely secure
hugo@... carfax.org.uk | understands neither systems nor security.
http://carfax.org.uk/ |
PGP: E2AB1DE4 | Bruce Schneier
prev parent reply other threads:[~2020-11-27 16:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-27 15:11 btrfs metadata mirroring Zener
2020-11-27 16:09 ` Hugo Mills [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=20201127160937.GF1908@savella.carfax.org.uk \
--to=hugo@carfax.org.uk \
--cc=linux-btrfs@vger.kernel.org \
--cc=zener78@gmail.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