Re: [PATCH] Btrfs: fix order by which delayed references are run

2015-07-26 Thread Qu Wenruo
Hi Filipe, Sorry for the late reply after it is already merged, but I'm a little concerned about the extra loop to find the first inc delayed ref. It may take some extra time when there are a lot of delayed refs. What about allowing deleting the extent item at dec delayed ref time and then a

[PATCH] btrfs-progs-tests: Add '-o loop' to mount command line in convert-tests.sh

2015-07-26 Thread Zhaolei
From: Zhao Lei To fix following bug: # ./convert-tests.sh [TEST] ext2 4k nodesize, btrfs defaults failed: mount /root/btrfsprogs/tests/test.img /root/btrfsprogs/tests/mnt # tail convert-tests-results.txt ... ### mount /root/btrfsprogs/tests/test.img /root/btrfsprogs/tests

[PATCH v2 2/7] btrfs-progs: Move close timer handle code to line after sub process exit

2015-07-26 Thread Zhaolei
From: Zhao Lei The timer handle have possibility in using by sub thread, better to close it after sub process exit. Signed-off-by: Zhao Lei --- task-utils.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/task-utils.c b/task-utils.c index 0390a69..17fd573 100644 --- a

[PATCH v2 6/7] btrfs-progs: Move code to create loop device to common

2015-07-26 Thread Zhaolei
From: Zhao Lei This code block is common used, move it to common function will make code clean. Signed-off-by: Zhao Lei --- tests/common | 16 tests/fsck-tests/013-extent-tree-rebuild/test.sh | 11 +-- tests/misc-tests/001-btrfstune-

[PATCH v2 7/7] btrfs-progs: Introduce a misc test for thread conflict in btrfs-convert

2015-07-26 Thread Zhaolei
From: Zhao Lei Current code of btrfs-convert have a bug of thread conflict, which caused invalid memory accessing between threads, and make program panic. This patch add a test item for above bug, as: # ./misc-tests.sh [TEST] 001-btrfstune-features [TEST] 002-uuid-rewrite [TEST]

[PATCH v2 5/7] btrfs-progs: Set info->periodic.timer_fd to 0 in init-fail

2015-07-26 Thread Zhaolei
From: Zhao Lei In current code, (info->periodic.timer_fd == 0) means it is not valid, as: if (info->periodic.timer_fd) { close(info->periodic.timer_fd); ... We need set its value from -1 to 0 in create-fail case, to make code like above works. Signed-off-by: Zhao Lei --- task-ut

[PATCH v2 1/7] btrfs-progs: Fix wrong address accessing by subthread in btrfs-convert

2015-07-26 Thread Zhaolei
From: Zhao Lei btrfs-convert sometimes show 'Assertion failed' in converting a nearly blank file system, as: create btrfs filesystem: blocksize: 4096 nodesize: 16384 features: extref, skinny-metadata (default) creating btrfs metadata. creating ext2fs image f

[PATCH v2 3/7] btrfs-progs: Remove cleanup-timer code for btrfs-convert

2015-07-26 Thread Zhaolei
From: Zhao Lei No need to close timer handle afain in subthread-close-callback, it is closed by task_stop() automatically. This patch also add a fflush() to make log output on time. Signed-off-by: Zhao Lei --- btrfs-convert.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --gi

[PATCH v2 4/7] btrfs-progs: resst info->periodic.timer_fd's value after free

2015-07-26 Thread Zhaolei
From: Zhao Lei task_period_stop() is used to close a timer explicitly, to avoid the timer handle closed again by task_stop(), we should reset its value after close. Also add value-reset for info->id for safe. Signed-off-by: Zhao Lei --- task-utils.c | 6 +- 1 file changed, 5 insertions(+)

[PATCH v2 0/7] btrfs-progs: Fix wrong address accessing by subthread in btrfs-convert

2015-07-26 Thread Zhaolei
From: Zhao Lei It is v2 patchset of: Fix wrong address accessing by subthread in btrfs-convert. Changelog: 1: Move bug test script from patch description into a single script in test/misc-tests, suggested-by: David Sterba 2: Move code for creating loop device to common [PATCH 6/7] Zhao

Re: systemd : Timed out waiting for defice dev-disk-by…

2015-07-26 Thread Duncan
Philip Seeger posted on Sun, 26 Jul 2015 22:39:04 +0200 as excerpted: > Hi, > >> 50% of the time when booting, the system go in safe mode because my 12x >> 4TB RAID10 btrfs is taking too long to mount from fstab. > > This won't help, but I've seen this exact behavior too (some time ago). > Excep

Re: btrfs partition converted from ext4 becomes read-only minutes after booting: WARNING: CPU: 2 PID: 2777 at ../fs/btrfs/super.c:260 __btrfs_abort_transaction+0x4b/0x120

2015-07-26 Thread Robert Munteanu
On Fri, Jul 10, 2015 at 3:34 AM, Qu Wenruo wrote: > One of my patch addressed a problem that a converted btrfs can't pass > btrfsck. > > Not sure if that is the cause, but if you can try btrfs-progs v3.19.1, the > one without my btrfs-progs patches and some other newer convert related > patches, a

Re: systemd : Timed out waiting for defice dev-disk-by…

2015-07-26 Thread Philip Seeger
Hi, 50% of the time when booting, the system go in safe mode because my 12x 4TB RAID10 btrfs is taking too long to mount from fstab. This won't help, but I've seen this exact behavior too (some time ago). Except that it wasn't 50% that it didn't work, more like almost everytime. Commenting ou

oops - fs/btrfs/extent-tree.c:2025 - kernel 4.2.0-rc3 - __btrfs_inc_extent_ref:2025: errno=-17 Object already exists

2015-07-26 Thread David Goodwin
Filesystem was being balanced with : btrfs balance start -dusage=55 -musage=55 $filesystem when this happened : [ cut here ] WARNING: CPU: 2 PID: 31502 at fs/btrfs/extent-tree.c:2025 __btrfs_inc_extent_ref.isra.51+0x210/0x280 [btrfs]() BTRFS: Transaction aborted (error