Re: Oops with a "degraded" volume

2012-09-16 Thread Liu Bo
On 09/15/2012 10:17 PM, Antoine Sirinelli wrote: > Hi, > > I have experienced a very reproducible Oops within the btrfs driver. On > a linux 3.5.4, if I mount a volume with the option "degraded" because > one of the device is missing, I would get an Oops when I unmount it (or > even before). You c

[PATCH] Btrfs: fix double decrease of the writer counter

2012-09-16 Thread Miao Xie
In __btrfs_end_transaction(), we have invoked sb_end_intwrite(), but if we need run btrfs_commit_transaction(), we will decrease the writer counter for two times because btrfs_commit_transaction() also invokes sb_end_intwrite(). Fix it. Signed-off-by: Miao Xie --- fs/btrfs/transaction.c |4 +

Re: [PATCH] Btrfs: fix race with freeze and free space inodes

2012-09-16 Thread Miao Xie
On fri, 14 Sep 2012 11:26:20 -0400, Josef Bacik wrote: > So we start our freeze, somebody comes in and does an fsync() on a file > where we have to commit a transaction for whatever reason, and we will > deadlock because the freeze is waiting on FS_FREEZE people to stop writing > to the file system

Re: [PATCH] Btrfs + Btrfs-progs: make pipe functions re-usable

2012-09-16 Thread Anand Jain
btrfs send introduced a part of code to read kernel-data from user-end using pipe. We need this part of code to be useable outside of send sub-cmd, so that developing service sub-cmd can use it. What's 'service sub-cmd' please? at the moment 'btrfs service history |' to show logs

'umount' of multi-device volume hangs until the device is physically un-plugged

2012-09-16 Thread Kay Sievers
I'm currently playing around with native btrfs multi-device support in systemd. There might be a few "hotplug issues" to solve, here is the first one: A mounted (otherwise unused) multi-device volume (USB multi-slot card reader), hangs at: $ umount /mnt with (fedora) kernel 3.6.0-0.rc5.git0.1.

Re: [PATCH 1/2] Btrfs: cleanup duplicated division functions

2012-09-16 Thread Miao Xie
On fri, 14 Sep 2012 15:54:18 +0200, David Sterba wrote: > On Thu, Sep 13, 2012 at 06:51:36PM +0800, Miao Xie wrote: >> div_factor{_fine} has been implemented for two times, cleanup it. >> And I move them into a independent file named math.h because they are >> common math functions. > > You remove

Re: [PATCH] Btrfs: use vfree instead of kfree

2012-09-16 Thread David Sterba
On Fri, Sep 14, 2012 at 01:05:09PM -0400, Josef Bacik wrote: > We are vmalloc()'ing the fspath now so we should be vfree'ing it and not > kfreeing it. Thanks, > > Reported-by: Dave Sterba > Signed-off-by: Josef Bacik IMO better to fold this change into the patch that introduced it, as it's not

btrfs: open_ctree failed on external usb drive

2012-09-16 Thread Sébastien Kalt
Hi, I have formated a previous ntfs partition to btrfs using gparted last week. It's an external usb drive. I used it to backup another disk, then moving the datas back to the other disk. I ran a crashplan backup and a couple of rsync of my home directory. I moved back to this disk some data. I