[PATCH] Btrfs: add missing free_extent_buffer

2015-05-25 Thread Liu Bo
read_tree_block may take a reference on the 'eb', a following free_extent_buffer is necessary. Signed-off-by: Liu Bo bo.li@oracle.com --- fs/btrfs/extent-tree.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c index 8b353ad..bb8a221 100644

[PATCH 2/2] [PATCH 2/2] Btrfs: fix up read_tree_block to return proper error

2015-05-25 Thread Liu Bo
The return value of read_tree_block() can confuse callers as it always returns NULL for either -ENOMEM or -EIO, so it's likely that callers parse it to a wrong error, for instance, in btrfs_read_tree_root(). This fixes the above issue. Signed-off-by: Liu Bo bo.li@oracle.com --- This is based

[PATCH 1/2 RESEND] Btrfs: add missing free_extent_buffer

2015-05-25 Thread Liu Bo
read_tree_block may take a reference on the 'eb', a following free_extent_buffer is necessary. Signed-off-by: Liu Bo bo.li@oracle.com --- This is based on the latest for-linus-4.1. fs/btrfs/extent-tree.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/btrfs/extent-tree.c

Re: [PATCH] fsck.btrfs: Fix bashism and bad getopts processing

2015-05-25 Thread David Sterba
On Thu, May 21, 2015 at 01:50:55PM +0100, Dimitri John Ledkov wrote: First fix == bashism, as that is not accepted by e.g. Debian/Ubuntu dash. Secondly shift OPTIND, such that last parameter is checked to exist. Signed-off-by: Dimitri John Ledkov dimitri.j.led...@intel.com ---

Re: [PATCH] Btrfs: add missing free_extent_buffer

2015-05-25 Thread David Sterba
On Mon, May 25, 2015 at 02:31:56PM +0200, David Sterba wrote: On Mon, May 25, 2015 at 05:16:40PM +0800, Liu Bo wrote: read_tree_block may take a reference on the 'eb', a following free_extent_buffer is necessary. Signed-off-by: Liu Bo bo.li@oracle.com Reviewed-by: David Sterba

Re: [PATCH] Btrfs: add missing free_extent_buffer

2015-05-25 Thread David Sterba
On Mon, May 25, 2015 at 05:16:40PM +0800, Liu Bo wrote: read_tree_block may take a reference on the 'eb', a following free_extent_buffer is necessary. Signed-off-by: Liu Bo bo.li@oracle.com Reviewed-by: David Sterba dste...@suse.cz And I've spotted one more in btrfs_read_tree_root and 2

Re: Additional Debug and other various pr_ additions

2015-05-25 Thread David Sterba
On Sun, May 24, 2015 at 09:42:19PM -0500, Anthony Plack wrote: Would I step on anyone’s toes if I started submitting some extra patches to increase the verbosity of the BTRFS code in the kernel log? I would probably start with most things as pr_debug just to keep it quiet on non-debug

Re: [PATCH v2] btrfs-progs: Enhance read_tree_block to avoid memory corruption

2015-05-25 Thread David Sterba
On Fri, May 22, 2015 at 09:01:23AM +0800, Qu Wenruo wrote: Add the following tree block check to avoid memory corruption on hostile image: 1) Check level. Level = BTRFS_MAX_LEVEL won't be read out. 2) Nritems. For nr_items max_nritems, the tree_block won't be read out. Max nritems is

[PATCH] Btrfs: Log the error conditions to determine which caused the error in btrfs_init_inode_security

2015-05-25 Thread Anthony Plack
On May 25, 2015, at 7:57 AM, David Sterba dste...@suse.cz wrote: On Sun, May 24, 2015 at 09:42:19PM -0500, Anthony Plack wrote: Would I step on anyone’s toes if I started submitting some extra patches to increase the verbosity of the BTRFS code in the kernel log? I would probably start

Re: Did convert do anything?

2015-05-25 Thread Anthony Plack
On May 24, 2015, at 11:00 PM, Gareth Pye gar...@cerberos.id.au wrote: 2. 18% or 1.1T spare currently. That isn't what I'd call tiny free space. -- # btrfs fi df /data Data, RAID1: total=4.43TiB, used=4.41TiB Of 4.43TiB, btrfs believes you have used 4.41TiB. Chris’s fix to this has

Help needed to recover a RAID5 btrfs

2015-05-25 Thread Felix Koop
Hello, I have a RAID5 filesystem where one disk has crashed. Now the filesystem is not recognized any more. Any help available? Here is some info: root@server:~# uname -a Linux server 4.0.0-1-amd64 #1 SMP Debian 4.0.2-1 (2015-05-11) x86_64 GNU/Linux root@server:~# btrfs --version btrfs-progs

booting btrfs RAID with dracut/systemd results in open_ctree failed

2015-05-25 Thread Kai Krakow
Hi! I need to boot with dracut to get my btrfs root partition properly initialized (because it is a multi-device btrfs). Today, after upgrading to systemd v220, I tracked a booting issue down to what looks like a general problem with the btrfs udev rules distributed with systemd: If I drop

Re: Did convert do anything?

2015-05-25 Thread Gareth Pye
After a full balance that is likely to change to 4.41TiB used of 4.41TiB total. Is that going to help anything, Peter is saying it's a known bug that convert can't do anything currently. On Tue, May 26, 2015 at 2:36 AM, Anthony Plack t...@plack.net wrote: On May 24, 2015, at 11:00 PM, Gareth

Re: Did convert do anything?

2015-05-25 Thread Chris Murphy
Looks like it's in 4.1rc5. https://git.kernel.org/cgit/linux/kernel/git/mason/linux-btrfs.git/commit/?h=for-linus-4.1id=153c35b60c72de9fae06c8e2c8b2c47d79d4 -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More

Re: Help needed to recover a RAID5 btrfs

2015-05-25 Thread Duncan
Felix Koop posted on Mon, 25 May 2015 18:06:20 +0200 as excerpted: I have a RAID5 filesystem where one disk has crashed. Now the filesystem is not recognized any more. Any help available? Here is some info: root@server:~# uname -a Linux server 4.0.0-1-amd64 #1 SMP Debian 4.0.2-1

Re: Help needed to recover a RAID5 btrfs

2015-05-25 Thread Qu Wenruo
Hello, I have a RAID5 filesystem where one disk has crashed. Now the filesystem is not recognized any more. Any help available? Here is some info: root@server:~# uname -a Linux server 4.0.0-1-amd64 #1 SMP Debian 4.0.2-1 (2015-05-11) x86_64 GNU/Linux root@server:~# btrfs --version btrfs-progs