All of lore.kernel.org
 help / color / mirror / Atom feed
From: Roman Mamedov <rm@romanrm.net>
To: Robert White <rwhite@pobox.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Can't cp --reflink files on a Ext4-converted FS w/o checksums
Date: Thu, 27 Nov 2014 04:33:37 +0500	[thread overview]
Message-ID: <20141127043337.198d6084@natsu> (raw)
In-Reply-To: <54765FC2.2050309@pobox.com>

On Wed, 26 Nov 2014 15:18:26 -0800
Robert White <rwhite@pobox.com> wrote:

> So you _could_ reflink the file but you'd have to do it to another file 
> with no data checksums -- which basically means a NOCOW file, or 
> mounting with nodatasum while you do the reflink, but now you have more 
> problem files.

Bingo!!! A cp --reflink to a destination that's been made chattr +C prior to
that, works perfectly.

My goal was to convert regular top-level directories into subvolumes (for
further snapshotting). With that trick, I've been able to do that now w/o
issues.

$ mv Music Music.orig
$ sudo btrfs sub create Music
Create subvolume './Music'
$ sudo chattr +C Music
$ sudo cp -a --reflink Music.orig/* Music/
$ 

Finished with no rewriting necessary. After that I recursively-removed the +C
attribute from all newly reflinked files, and cp --reflink as well as
snapshotting of those works fine.

Thanks for the idea. :)

-- 
With respect,
Roman

  reply	other threads:[~2014-11-26 23:33 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-26 19:55 Can't cp --reflink files on a Ext4-converted FS w/o checksums Roman Mamedov
2014-11-26 23:18 ` Robert White
2014-11-26 23:33   ` Roman Mamedov [this message]
2014-11-27  0:00     ` Robert White
2014-11-27  0:20       ` Roman Mamedov
2014-11-27  0:31         ` Robert White
2014-11-27  0:57           ` Robert White
2014-11-27  0:20     ` Robert White
2014-11-27  0:28       ` Roman Mamedov
2014-11-27  0:45         ` Robert White
2014-11-27  9:27   ` Duncan
2014-11-28  7:12     ` Robert White
2014-11-27  3:31 ` Liu Bo

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=20141127043337.198d6084@natsu \
    --to=rm@romanrm.net \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=rwhite@pobox.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.