Re: [PATCH] btrfs: allow mounting btrfs subvolumes with different ro/rw options

2013-09-02 Thread Harald Hoyer
On 06/18/2013 05:29 PM, har...@redhat.com wrote: From: Harald Hoyer har...@redhat.com Given the following /etc/fstab entries: /dev/sda3 /mnt/foo btrfs subvol=foo,ro 0 /dev/sda3 /mnt/bar btrfs subvol=bar,rw 0 you can't issue: $ mount /mnt/foo $ mount /mnt/bar You would have to do:

[PATCH] Btrfs: more efficient inode tree replace operation

2013-09-02 Thread Filipe David Borba Manana
Instead of removing the current inode from the red black tree and then add the new one, just use the red black tree replace operation, which is more efficient. Signed-off-by: Filipe David Borba Manana fdman...@gmail.com --- fs/btrfs/inode.c | 10 +- 1 file changed, 5 insertions(+), 5

Re: [PATCH v7] Btrfs: optimize key searches in btrfs_search_slot

2013-09-02 Thread David Sterba
On Sun, Sep 01, 2013 at 11:39:28AM +0100, Filipe David Borba Manana wrote: +#ifdef CONFIG_BTRFS_ASSERT +static int key_search_validate(struct extent_buffer *b, +struct btrfs_key *key, +int level) +{ ... +} +#endif + +static int

Re: [PATCH 1/3] Btrfs-progs: Add Makefile infrastructure for subdirs

2013-09-02 Thread David Sterba
On Tue, Jun 11, 2013 at 06:15:17PM -0500, Eric Sandeen wrote: Preparatory patch to move cmd test files into their own subdirs. I'm adding this to integration as it's just an infrastructure change, but there are some bits missing before we can move more .c files into their own subdirs. More

Re: [PATCH v7] Btrfs: optimize key searches in btrfs_search_slot

2013-09-02 Thread Filipe David Manana
On Mon, Sep 2, 2013 at 2:39 PM, David Sterba dste...@suse.cz wrote: On Sun, Sep 01, 2013 at 11:39:28AM +0100, Filipe David Borba Manana wrote: +#ifdef CONFIG_BTRFS_ASSERT +static int key_search_validate(struct extent_buffer *b, +struct btrfs_key *key, +

Re: [PATCH 3/3 V2] Btrfs-progs: move btrfs cmd files to cmd/ subdir

2013-09-02 Thread David Sterba
On Tue, Jun 11, 2013 at 07:38:03PM -0500, Eric Sandeen wrote: Move btrfs cmd files to cmd/ subdir Are you ok with naming the subdirectory 'cmds'? david -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo

Re: [PATCH v7] Btrfs: optimize key searches in btrfs_search_slot

2013-09-02 Thread David Sterba
On Mon, Sep 02, 2013 at 03:40:39PM +0100, Filipe David Manana wrote: Between patch versions v5 to v7, I don't have any strong preference. All have correct, small and simple code. I'm ok with v7. -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to

btrfs_join_transaction bug...

2013-09-02 Thread Daniel J Blueman
When running my btrfs exerciser [1] for ~5 mins on 3.11-rc7, I hit a BUG_ON in merge_reloc_roots that asserts btrfs_join_transaction doesn't generate an error [2]. Is this a valid failure when the filesystem went read-only due to out of space? It can also reproduce a livelock between a 'btrfs

Re: [RFC PATCH v6 5/5] Btrfs: online data deduplication

2013-09-02 Thread David Sterba
I wanted to only comment on the ioctl and interface to userspace bits, but found more things to comment in the kernel code. On Thu, Aug 08, 2013 at 04:35:45PM +0800, Liu Bo wrote: --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h @@ -94,6 +95,9 @@ struct btrfs_ordered_sum; /* for storing balance

Re: uncorrectable errors after btrfs replace

2013-09-02 Thread Stefan Behrens
On Sun, 25 Aug 2013 20:07:32 -0600, Chris Murphy wrote: On Aug 25, 2013, at 4:10 PM, Stuart Pook slp644...@pook.it wrote: I emailed them to Stefan Behrens Chris Murphy. Please let me know if you did not get them (presumably because they are too big). Observations: 1. The problems

Re: [PATCH v2] Btrfs-progs: add dedup subcommand

2013-09-02 Thread David Sterba
On Mon, Aug 12, 2013 at 10:45:55AM +0800, Liu Bo wrote: On Fri, Aug 09, 2013 at 02:51:35PM +0200, David Sterba wrote: I'm not sure that calling it register/unregister is the right thing, IMO it's more enable/disable as you write in the documentation under each respective command. Both

Re: [PROGS PATCH] Import btrfs-extent-same

2013-09-02 Thread David Sterba
On Tue, Aug 13, 2013 at 12:35:15PM -0700, Mark Fasheh wrote: Can you (or Mark) please turn it into a subcommand of dedup? The idea is to merge both in-bound and out-bound dedup into one command, eg. btrfs dedup files dir/* I can handle this - it's pretty easy but we have to talk about

Re: [PATCH] btrfs: return btrfs error code for dev excl ops err

2013-09-02 Thread David Sterba
On Tue, Aug 20, 2013 at 02:34:05PM -0400, Josef Bacik wrote: --- a/include/uapi/linux/btrfs.h +++ b/include/uapi/linux/btrfs.h @@ -505,8 +505,7 @@ static inline char *btrfs_err_str(enum btrfs_err_code err_code) case BTRFS_ERROR_DEV_ONLY_WRITABLE: return

Re: [PATCH] rwsem: add rwsem_is_contended

2013-09-02 Thread Peter Hurley
On 09/01/2013 04:32 AM, Michel Lespinasse wrote: Hi Josef, On Fri, Aug 30, 2013 at 7:14 AM, Josef Bacik jba...@fusionio.com wrote: Btrfs uses an rwsem to control access to its extent tree. Threads will hold a read lock on this rwsem while they scan the extent tree, and if need_resched() they

Recovering from csum errors

2013-09-02 Thread Rain Maker
Hello list, I was greeted by the following errors in my syslog: Sep 2 23:06:08 laptop kernel: [ 7340.809551] btrfs: checksum error at logical 271008116736 on dev /dev/dm-0, sector 540863448, root 442, inode 1508, offset 10128658432, length 4096, links 1 (path: Werkstation/Windows 8 x64-cl1.vmdk)

Re: Recovering from csum errors

2013-09-02 Thread Hugo Mills
On Mon, Sep 02, 2013 at 11:41:12PM +0200, Rain Maker wrote: Hello list, So, I ran a full scrub, and, luckily, it only found 6 csum errors (these 6). The damage therefore seems to be contained in just 1 file. Now, I removed the offending file. But is there something else I should have

Re: Recovering from csum errors

2013-09-02 Thread Rain Maker
First of all, thanks for the quick response. Reply inline. 2013/9/3 Hugo Mills h...@carfax.org.uk: On Mon, Sep 02, 2013 at 11:41:12PM +0200, Rain Maker wrote: Now, I removed the offending file. But is there something else I should have done to recover the data in this file? Can it be

[PATCH] btrfs-progs: fix parallel build

2013-09-02 Thread rongqing.li
From: Roy.Li rongqing...@windriver.com Parallel execution of make install may fail due to late creation of version.h, fix it by adding the dependence on version.h. The fix is similar to 7aaf00fc[btrfs-progs: fix parallel build] Signed-off-by: Roy.Li rongqing...@windriver.com --- Makefile |