From: sri <toyours_sridhar@yahoo.co.in>
To: linux-btrfs@vger.kernel.org
Subject: btrfs multi device handling
Date: Fri, 17 Jun 2016 09:18:04 +0000 (UTC) [thread overview]
Message-ID: <loom.20160617T110624-71@post.gmane.org> (raw)
I am trying to understand how btrfs handles multiple devices configured to
a single btrfs file system.
As compared to traditinal LVM2, say 2 physical disks /dev/sda, /dev/sdb
are configured as single LVM2 pool and lvm provide an abstract view say
/dev/mapper/VG1-LV1 where VG1 is name of volume ground created on top of
/dev/sda and /dev/sdb and LV1 is logical volume.
for mkfs, we can provide /dev/mapper/VG1-LV1 to create file system. This
path is kind of virtual device managed by LVM2. and Using dm, I/Os are
transferred to respective devices /dev/sda or /dev/sdb.
Does btrfs also creates such virtual view of all devices provided while
operating on disks under the file system?
To support my question, example is mkfs.btrfs /dev/sdc /dev/sdd creates
btrfs. Both disks are of size 5GB. Hence around 10GB btrfs fs is created.
For this btrfs internally creates any virtual path for 10GB view? or how
btrfs internally manages?
I am looking at scrub code where struct btrfs_device structure contains
struct block_device *bdev and also struct btrfs_fs_devices *fs_devices
fields.
If I relate my question does bdev filed in btrfs_device is virtual view of
all devices? and fs_devices represents list of individual devices (in
above example /dev/sdc and /dev/sdd) ?
Thank you in advance.
next reply other threads:[~2016-06-17 9:18 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-17 9:18 sri [this message]
2016-06-22 5:56 ` btrfs multi device handling sri
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=loom.20160617T110624-71@post.gmane.org \
--to=toyours_sridhar@yahoo.co.in \
--cc=linux-btrfs@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;
as well as URLs for NNTP newsgroup(s).