Re: device delete to get errors from the kernel

2013-04-30 Thread Anand Jain
Thanks Stefan. :: About the issue you mentioned, that you need to change the kernel and the user mode at the same time: You can keep it compatible. Just do not delete the old kernel interface. The user mode program could try the new interface first, and if it fails, fall back to the old

WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Alexander Skwar
Hello On my HP Compaq dc5800 with Ubuntu 13.04 and their 3.8.0-19-lowlatency kernel, I've got quite some kernel traces in the syslog. You can find them below or at http://pastebin.com/bLXPBX67 (to avoid line breaks…). These kernel traces all begin with: WARNING: at

Re: [PATCH] xfstests 311: test fsync with dm flakey V3

2013-04-30 Thread Dave Chinner
On Fri, Apr 26, 2013 at 03:13:59PM -0400, Josef Bacik wrote: This test sets up a dm flakey target and then runs my fsync tester I've been using to verify btrfs's fsync() is working properly. It will create a dm flakey device, mount it, run my test, make the flakey device start dropping

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Helmut Hullen
Hallo, Alexander, Du meintest am 30.04.13: On my HP Compaq dc5800 with Ubuntu 13.04 and their 3.8.0-19-lowlatency kernel, I've got quite some kernel traces in the syslog. It's a very good idea to use the newest kernel for btrfs. 3.8.0 is really old. Just try kernel 3.8.10. Viele Gruesse!

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Hugo Mills
On Tue, Apr 30, 2013 at 08:55:00AM +0200, Helmut Hullen wrote: Hallo, Alexander, Du meintest am 30.04.13: On my HP Compaq dc5800 with Ubuntu 13.04 and their 3.8.0-19-lowlatency kernel, I've got quite some kernel traces in the syslog. It's a very good idea to use the newest kernel

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Alexander Skwar
Hugo Mills hugo at carfax.org.uk writes: The differences in btrfs between the two are very small, and even I(*) wouldn't call 3.8.0 very old quite yet, given that 3.9 was only released yesterday. From memory, there's one btrfs patch in the 3.8 stable series. Your problem is just a

[PATCH] Btrfs: cleanup destroy_marked_extents V3

2013-04-30 Thread Josef Bacik
We can just look up the extent_buffers for the range and free stuff that way. This makes the cleanup a bit cleaner and we can make sure to evict the extent_buffers pretty quickly by marking them as stale. Thanks, Signed-off-by: Josef Bacik jba...@fusionio.com --- V2-V3: I wanted to use

Re: device delete to get errors from the kernel

2013-04-30 Thread Anand Jain
Thanks for the comments. V2 is out. Here I followed the choice #1 as review suggested. which is to update the error code. However I have them in uapi/linux/btrfs.h (not in errno.h though I meant it to be there in the first place). pls do let me know your review comments. Thanks,

[PATCH v2] btrfs: device delete to get errors from the kernel

2013-04-30 Thread Anand Jain
v1-v2: introduce error codes for the device mgmt usage v1: adds a parameter in the ioctl arg struct to carry the error string Signed-off-by: Anand Jain anand.j...@oracle.com --- fs/btrfs/ioctl.c | 22 +++--- fs/btrfs/volumes.c | 26 +++---

[PATCH v2] btrfs-progs: device delete to get errors from the kernel

2013-04-30 Thread Anand Jain
v1-v2: introduce error codes for the device mgmt usage v1: add another parameter to the ioctl arg structure to carry the error string Signed-off-by: Anand Jain anand.j...@oracle.com --- cmds-device.c | 10 -- ioctl.h | 37 + 2 files changed, 45

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Josef Bacik
On Tue, Apr 30, 2013 at 05:51:17AM -0600, Alexander Skwar wrote: Hugo Mills hugo at carfax.org.uk writes: The differences in btrfs between the two are very small, and even I(*) wouldn't call 3.8.0 very old quite yet, given that 3.9 was only released yesterday. From memory, there's one

Re: [PATCH] Btrfs: fix off-by-one in lseek

2013-04-30 Thread David Sterba
On Wed, Jan 09, 2013 at 12:34:45PM +0800, Liu Bo wrote: Thanks for coding this up, I've checked the code, these messages can be fixed by the following, please check if it works on your side :) diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 1b319df..1688669 100644 ---

[PATCH] btrfs: add debug check for extent_io range alignment

2013-04-30 Thread David Sterba
The 'end' value must exactly cover the end of the interval, which means one byte less than the expected block alignment, or in case of a file smaller than one block, one byte less than the inode size. Signed-off-by: David Sterba dste...@suse.cz --- fs/btrfs/extent_io.c | 27

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Alexander Skwar
Hello Josef On Tue, Apr 30, 2013 at 3:58 PM, Josef Bacik jba...@fusionio.com wrote: So we deal with this case fine, but it really shouldn't be happening, it only happens if your block groups are way too large, which again shouldn't be happening. Can you run fsck on this device and see if it

Re: [PATCH] btrfs: add debug check for extent_io range alignment

2013-04-30 Thread Hugo Mills
On Tue, Apr 30, 2013 at 04:29:44PM +0200, David Sterba wrote: The 'end' value must exactly cover the end of the interval, which means one byte less than the expected block alignment, or in case of a file smaller than one block, one byte less than the inode size. If that's actually the case,

[PATCH v2] btrfs: add debug check for extent_io range alignment

2013-04-30 Thread David Sterba
The 'end' value must exactly cover the end of the interval, which means one byte less than the expected block alignment, or in case of a file smaller than one block, one byte less than the inode size. Signed-off-by: David Sterba dste...@suse.cz --- v1-v2: denote that range is inclusive [...]

Moving to bugzilla.kernel.org

2013-04-30 Thread Josef Bacik
Hello, In an effort to be better about helping users with their bugs I've gotten control over the btrfs component of bugzilla.kernel.org. I'm currently going through all the bugs in this list and closing out the old ones (which is most of them). From now on I'd like us to push users who report

[PATCH 0/3] A few message cleanups

2013-04-30 Thread David Sterba
I'm running tests with SANITY_CHECKS enabled and saw that the messages were not printed with a prefix, fixed. And updated a some lines along the way. Patches are interdependent. David Sterba (3): btrfs: add prefix to sanity tests messages btrfs: move ifdef around sanity checks out of

[PATCH 1/3] btrfs: add prefix to sanity tests messages

2013-04-30 Thread David Sterba
And change the message level to KERN_INFO. Signed-off-by: David Sterba dste...@suse.cz --- fs/btrfs/free-space-cache.c | 97 ++- 1 files changed, 49 insertions(+), 48 deletions(-) diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c

[PATCH 2/3] btrfs: move ifdef around sanity checks out of init_btrfs_fs

2013-04-30 Thread David Sterba
Signed-off-by: David Sterba dste...@suse.cz --- fs/btrfs/free-space-cache.c |4 +++- fs/btrfs/free-space-cache.h |2 -- fs/btrfs/super.c|2 -- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/fs/btrfs/free-space-cache.c b/fs/btrfs/free-space-cache.c index

[PATCH 3/3] btrfs: show compiled-in config features at module load time

2013-04-30 Thread David Sterba
We want to know if there are debugging features compiled in, this may affect performance. The message is printed before the sanity checks. Also kill version.h file that serves no purpose, we don't use any version tag for kernel module. Signed-off-by: David Sterba dste...@suse.cz ---

[PATCH] Btrfs: fix typo in send.c

2013-04-30 Thread Josef Bacik
A user reported a bug where we do sizeof(*ptr * count) instead of sizeof(*ptr) * count. Fix this. Reported-by: David Binderman dcb...@hotmail.com Signed-off-by: Josef Bacik jba...@fusionio.com --- fs/btrfs/send.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH] btrfs: annotate quota tree for lockdep

2013-04-30 Thread David Sterba
Quota tree has been missing from lockdep annotations, though no warning has been seen in the wild. There's currently one entry that does not belong there, BTRFS_ORPHAN_OBJECTID. No such tree exists, it's probably a copy paste mistake, the id is defined among tree ids. Signed-off-by: David

Re: WARNING: at fs/btrfs/free-space-cache.c:921 __btrfs_write_out_cache+0x6b9/0x9a0 [btrfs]()

2013-04-30 Thread Josef Bacik
On Tue, Apr 30, 2013 at 08:33:38AM -0600, Alexander Skwar wrote: Hello Josef On Tue, Apr 30, 2013 at 3:58 PM, Josef Bacik jba...@fusionio.com wrote: So we deal with this case fine, but it really shouldn't be happening, it only happens if your block groups are way too large, which