linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tydus Ken <kentydus@gmail.com>
To: linux-btrfs@vger.kernel.org
Subject: An issue when mounting the dd-copied partition and the original one together
Date: Fri, 20 Apr 2012 14:49:48 +0800	[thread overview]
Message-ID: <CAOLNCyrvxNi-wKYdPaUX9Qvpzi7RhVjDgmig-Mr1_M5HmXza2Q@mail.gmail.com> (raw)

Hi all.

I'm using btrfs for a long time. It's the time for me to report an issu=
e.

I use btrfs for my home and I dded the block device to a new computer.
It works well. But when I tried to mount both up and do syncing
between them, I found the two mountpoints are the same! i.e. when I
touch a file on my original partition, the same file appears in the
new one now. Vice versa.

I wrote a script to replay it (using loop, but result is the same):

=A0 =A0 dd if=3D/dev/zero of=3Dori.img bs=3D16M count=3D16
=A0 =A0 mkfs.btrfs ori.img
=A0 =A0 cp ori.img new.img
=A0 =A0 mkdir ori new
=A0 =A0 mount -o loop ori.img ori
=A0 =A0 mount -o loop new.img new
=A0 =A0 touch ori/foo
=A0 =A0 ls new

You'll see the file `foo' also appears in the `new' directory.

I guess there's something wrong with btrfs in how to deal with two
partition with same UUID or something else, but I'm not sure.

It's proved on Gentoo with Kernel 3.2.11, as well as Ubuntu with Kernel=
 3.1.9

Tydus
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" =
in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

             reply	other threads:[~2012-04-20  6:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-20  6:49 Tydus Ken [this message]
2012-04-20  7:20 ` An issue when mounting the dd-copied partition and the original one together Chris Samuel
2012-04-20  7:40   ` Jan Schmidt

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=CAOLNCyrvxNi-wKYdPaUX9Qvpzi7RhVjDgmig-Mr1_M5HmXza2Q@mail.gmail.com \
    --to=kentydus@gmail.com \
    --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).