[PATCH] Btrfs-progs: fix compile failure

2015-02-17 Thread Anand Jain
make :: [CC] btrfs-search-metadata.o btrfs-search-metadata.c: In function ‘print_usage’: btrfs-search-metadata.c:40: error: ‘BTRFS_BUILD_VERSION’ undeclared (first use in this function) btrfs-search-metadata.c:40: error: (Each undeclared identifier is reported only once

Re: btrfs raid-1 uuid-fstab

2015-02-17 Thread Duncan
Kai Krakow posted on Tue, 17 Feb 2015 00:15:50 +0100 as excerpted: Long story short: I managed to strip dracut down to too few modules and it lost its ability to mount anything and even could not spawn a shell. *gnarf Ouch! FWIW, that's why I use a kernel built-in initramfs. If I upgrade

Re: [PATCH 23/24] Btrfs: sysfs: support seed devices in the sysfs layout

2015-02-17 Thread Anand Jain
[guihc.f...@cn.fujitsu.com bounced removing the email id from the cc-list]. Dave, here is the patch list for Oct. https://patchwork.kernel.org/project/linux-btrfs/list/?page=7 v2 isn't there. I am confused. Anyway if btrfs-progs integration-20150213 contained V2. I am on it now. And I

Re: Forever blocked in bit_wait with kernel 3.19

2015-02-17 Thread Omar Sandoval
On Thu, Feb 12, 2015 at 11:12:25AM +, Steven Schlansker wrote: [ Please CC me on replies, I'm not on the list ] [ This is a followup to http://www.spinics.net/lists/linux-btrfs/msg41496.html ] Hello linux-btrfs, I've been having troubles keeping my Apache Mesos / Docker slave nodes

[PATCH] generic/325: Fix test case to work on 64K page size.

2015-02-17 Thread Chandan Rajendra
The test case passes 32K as the offset value to msync. This fails on machines with 64K page size. Fix this by creating a larger file and passing offset values which are multiples of 64K. Signed-off-by: Chandan Rajendra chan...@linux.vnet.ibm.com --- tests/generic/325 | 10 +-

Re: [PATCH v3] Btrfs: fix BUG_ON in btrfs_orphan_add() when delete unused block group

2015-02-17 Thread Chris Mason
On Wed, Feb 11, 2015 at 1:24 AM, Forrest Liu forre...@synology.com wrote: Removing large amount of block group in a transaction may encounters BUG_ON() in btrfs_orphan_add(). That is because btrfs_orphan_reserve_metadata() will grab metadata reservation from transaction handle, and

Re: [PATCH 2/3] btrfs: handle race on ENOMEM in alloc_extent_buffer

2015-02-17 Thread Omar Sandoval
On Tue, Feb 17, 2015 at 02:51:08AM -0800, Omar Sandoval wrote: Consider the following interleaving of overlapping calls to alloc_extent_buffer: Call 1: - Successfully allocates a few pages with find_or_create_page - find_or_create_page fails, goto free_eb - Unlocks the allocated pages

[PULL] Btrfs, recent cleanup patches

2015-02-17 Thread David Sterba
Hi, I've collected the cleanup patches that are not in the integration branch, the time span is last few months. I've reviewed them but tested only lightly due to yet unknown problems in the current integration branch. The target release is probably 3.21, I'm going to send more cleanup series so

[PATCH 3/3] btrfs: check io_ctl_prepare_pages return in __btrfs_write_out_cache

2015-02-17 Thread Omar Sandoval
If io_ctl_prepare_pages fails, the pages in io_ctl.pages are not valid. When we try to access them later, things will blow up in various ways. Signed-off-by: Omar Sandoval osan...@osandov.com --- fs/btrfs/free-space-cache.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff

[PATCH 2/3] btrfs: handle race on ENOMEM in alloc_extent_buffer

2015-02-17 Thread Omar Sandoval
Consider the following interleaving of overlapping calls to alloc_extent_buffer: Call 1: - Successfully allocates a few pages with find_or_create_page - find_or_create_page fails, goto free_eb - Unlocks the allocated pages Call 2: - Calls find_or_create_page and gets a page in call 1's

[PATCH 1/3] btrfs: handle ENOMEM in btrfs_alloc_tree_block

2015-02-17 Thread Omar Sandoval
This is one of the first places to go when memory is tight. Handle it properly rather than with a BUG_ON. Signed-off-by: Omar Sandoval osan...@osandov.com --- fs/btrfs/extent-tree.c | 41 - 1 file changed, 28 insertions(+), 13 deletions(-) diff --git

[PATCH 01/10] btrfs: Adjust commit-transaction condition to avoid NO_SPACE more

2015-02-17 Thread Zhaolei
From: Zhao Lei zhao...@cn.fujitsu.com If we have any chance to make a successful write, we should not give up. This patch adjust commit-transaction condition from: pinned = wanted to left + pinned = wanted Signed-off-by: Zhao Lei zhao...@cn.fujitsu.com --- fs/btrfs/extent-tree.c | 3 ++- 1

[PATCH] btrfs: Adjust commit-transaction condition to avoid NO_SPACE more

2015-02-17 Thread Zhaolei
From: Zhao Lei zhao...@cn.fujitsu.com If we have any chance to make a successful write, we should not give up. This patch adjust commit-transaction condition from: pinned = wanted to left + pinned = wanted Signed-off-by: Zhao Lei zhao...@cn.fujitsu.com --- fs/btrfs/extent-tree.c | 3 ++- 1

RE: [PATCH 01/10] btrfs: Adjust commit-transaction condition to avoid NO_SPACE more

2015-02-17 Thread Zhao Lei
Hi, From: Zhaolei [mailto:zhao...@cn.fujitsu.com] Subject: [PATCH 01/10] btrfs: Adjust commit-transaction condition to avoid NO_SPACE more Sorry for title, it is only one patch. Will resend. Thanks Zhaolei From: Zhao Lei zhao...@cn.fujitsu.com If we have any chance to make a

[PATCH 0/3] btrfs: ENOMEM bugfixes

2015-02-17 Thread Omar Sandoval
Hi, As it turns out, running with low memory is a really easy way to shake out undesirable behavior in Btrfs. This can be especially bad when considering that a memory limit is really easy to hit in a container (e.g., by using cgroup memory.limit_in_bytes). Here's a simple script that can hit