Re: ENOSPC / no space on very large devices

2016-07-28 Thread Stefan Priebe - Profihost AG
Am 20.07.2016 um 09:35 schrieb Holger Hoffstätte: > On 07/20/16 07:31, Stefan Priebe - Profihost AG wrote: >> Hi list, >> >> while i didn't had the problem for some month i'm now getting ENOSPC on >> a regular basis on one host. > > Well, it's getting better. :) Again the same problem. > >>

Re: ENOSPC / no space on very large devices

2016-07-28 Thread Stefan Priebe - Profihost AG
here we go... Am 20.07.2016 um 08:31 schrieb Wang Xiaoguang: > hello, > > On 07/20/2016 01:31 PM, Stefan Priebe - Profihost AG wrote: >> Hi list, >> >> while i didn't had the problem for some month i'm now getting ENOSPC on >> a regular basis on one host. >> >> It would be great if someone can

Re: [PATCH 2/5] New btrfs command: "btrfs inspect physical-find"

2016-07-28 Thread Goffredo Baroncelli
On 2016-07-29 03:34, Qu Wenruo wrote: >> I am not against about your proposal; however I have to point out >> that the goal of these command was not to *traverse* the file, but >> only to found the physical location of a file offset. My use case >> was to simulate a corruption of a raid5 stripe

Re: btrfs fi defrag does not defrag files >256kB?

2016-07-28 Thread Duncan
Nicholas D Steeves posted on Thu, 28 Jul 2016 13:53:31 -0400 as excerpted: > Additionally, I've read that -o autodefrag doesn't yet work well for > large databases. Would a supplementary targeted defrag policy be useful > here? For example: a general cron/systemd.trigger default of "-t 32M", >

Re: [PATCH 2/5] New btrfs command: "btrfs inspect physical-find"

2016-07-28 Thread Qu Wenruo
Hi, Goffredo, Sorry I forgot to mention that, even btrfs-map-logcal is an offline tool, it can still handle mount fs too. Although it's also true that it still lacks the needed RAID flags and stripe info. At 07/29/2016 04:25 AM, Goffredo Baroncelli wrote: Hi Qu, On 2016-07-28 03:47, Qu

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread Anatoly Pugachev
On Thu, Jul 28, 2016 at 9:04 PM, David Sterba wrote: > On Thu, Jul 28, 2016 at 04:28:41PM +0200, John Paul Adrian Glaubitz wrote: >> On 07/28/2016 04:25 PM, John Paul Adrian Glaubitz wrote: >> > On 07/28/2016 04:01 PM, Anatoly Pugachev wrote: >> >> Program received signal SIGBUS,

Re: [PATCH 2/5] New btrfs command: "btrfs inspect physical-find"

2016-07-28 Thread Goffredo Baroncelli
Hi Qu, On 2016-07-28 03:47, Qu Wenruo wrote: > At 07/28/2016 01:43 AM, Goffredo Baroncelli wrote: >> From: Goffredo Baroncelli >> >> The aim of this new command is to show the physical placement on the disk >> of a file. >> Currently it handles all the profiles (single, dup,

Re: [PATCH] Btrfs: deal with unexpected return value in flush_space

2016-07-28 Thread Liu Bo
On Thu, Jul 28, 2016 at 03:36:53PM +, Holger Hoffstätte wrote: > On Wed, 27 Jul 2016 18:42:03 -0700, Liu Bo wrote: > > > Function start_transaction() can return ERR_PTR(1) when flush is > > BTRFS_RESERVE_FLUSH_LIMIT, so the call graph is > > > > start_transaction (return ERR_PTR(1)) > > ->

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread David Sterba
On Thu, Jul 28, 2016 at 04:28:41PM +0200, John Paul Adrian Glaubitz wrote: > On 07/28/2016 04:25 PM, John Paul Adrian Glaubitz wrote: > > On 07/28/2016 04:01 PM, Anatoly Pugachev wrote: > >> Program received signal SIGBUS, Bus error. > >> 0x00177dfc in raid6_gen_syndrome (disks=4,

Re: btrfs fi defrag does not defrag files >256kB?

2016-07-28 Thread Nicholas D Steeves
On 28 July 2016 at 06:55, David Sterba wrote: > On Wed, Jul 27, 2016 at 01:19:01PM -0400, Nicholas D Steeves wrote: >> > In that regard a defrag -t 32M recommendation is reasonable for a >> > converted filesystem, tho you can certainly go larger... to 1 GiB as I >> > said. >> >>

[PATCH] btrfs-progs: fix memory leak with missing device

2016-07-28 Thread Justin Maggard
In read_one_chunk(), we may add an empty entry for a missing device. However, this entry wasn't being added to the dev_list, and so it never got freed. Signed-off-by: Justin Maggard --- volumes.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/volumes.c b/volumes.c

Re: btrfs fi defrag does not defrag files >256kB?

2016-07-28 Thread Duncan
David Sterba posted on Thu, 28 Jul 2016 12:55:55 +0200 as excerpted: > On Wed, Jul 27, 2016 at 01:19:01PM -0400, Nicholas D Steeves wrote: >> > In that regard a defrag -t 32M recommendation is reasonable for a >> > converted filesystem, tho you can certainly go larger... to 1 GiB as >> > I said.

Re: [PATCH] btrfs: Change RAID stripesize to a user-configurable option

2016-07-28 Thread Sanidhya Solanki
On Thu, 28 Jul 2016 13:32:27 +0200 David Sterba wrote: > I'll comment on the overall approach and skip code-specific comments. > > The changelog does not explain why there's a need for a new blockgroup > type and what's the relation to the existing types. It seems that it >

Re: [PATCH] Btrfs: deal with unexpected return value in flush_space

2016-07-28 Thread Holger Hoffstätte
On Wed, 27 Jul 2016 18:42:03 -0700, Liu Bo wrote: > Function start_transaction() can return ERR_PTR(1) when flush is > BTRFS_RESERVE_FLUSH_LIMIT, so the call graph is > > start_transaction (return ERR_PTR(1)) > -> btrfs_block_rsv_add (return 1) > -> reserve_metadata_bytes (return 1) >

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread Patrick Baggett
> Oh, and you will somehow need to guard this with #if BITS_PER_LONG == 64 ... > #else ... #endif respectively since you need to use different versions > (64 vs. 32) of get_unaligned_* depending on the size of unative_t. Maybe a get_unaligned_unative() would be better so that preprocessor fun is

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread John Paul Adrian Glaubitz
On 07/28/2016 04:25 PM, John Paul Adrian Glaubitz wrote: > On 07/28/2016 04:01 PM, Anatoly Pugachev wrote: >> Program received signal SIGBUS, Bus error. >> 0x00177dfc in raid6_gen_syndrome (disks=4, bytes=65536, >> ptrs=0x2c4510) at raid6.c:87 >> 87 wq0 = wp0 =

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread John Paul Adrian Glaubitz
On 07/28/2016 04:01 PM, Anatoly Pugachev wrote: > Program received signal SIGBUS, Bus error. > 0x00177dfc in raid6_gen_syndrome (disks=4, bytes=65536, > ptrs=0x2c4510) at raid6.c:87 > 87 wq0 = wp0 = *(unative_t *)[z0][d+0*NSIZE]; That should be easy to fix. Just make

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread Anatoly Pugachev
On Thu, Jul 28, 2016 at 3:24 PM, David Sterba wrote: > On Thu, Jul 28, 2016 at 02:09:03PM +0200, John Paul Adrian Glaubitz wrote: >> Hi David! >> >> On 07/28/2016 01:58 PM, Anatoly Pugachev wrote: >> >> Can you please test with the current 'devel' branch? Fixed by the patch >> >>

Btrfs progs pre-release 4.7-rc1

2016-07-28 Thread David Sterba
Hi, btrfs-progs 4.7-rc1 have been tagged. There are several new enhancements, a handful of bugfixes and other cleanups. The 4.7 release is planned for tomorrow. Changes: * convert: fix creating discontig extents * check: speed up traversing heavily reflinked extents within a file * check:

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread David Sterba
On Thu, Jul 28, 2016 at 02:09:03PM +0200, John Paul Adrian Glaubitz wrote: > Hi David! > > On 07/28/2016 01:58 PM, Anatoly Pugachev wrote: > >> Can you please test with the current 'devel' branch? Fixed by the patch > >> "btrfs-progs: fix unaligned access calculating raid56 data" (depends on > >>

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread John Paul Adrian Glaubitz
Hi David! On 07/28/2016 01:58 PM, Anatoly Pugachev wrote: >> Can you please test with the current 'devel' branch? Fixed by the patch >> "btrfs-progs: fix unaligned access calculating raid56 data" (depends on >> another patch in devel). Thanks. Are you sure you pushed these changes? I don't see

Re: [PATCH] btrfs-progs: fix btrfsck of space_cache=v2 bitmaps on big-endian

2016-07-28 Thread David Sterba
On Fri, Jul 15, 2016 at 12:12:48PM -0700, Omar Sandoval wrote: > From: Omar Sandoval > > Copy le_test_bit() from the kernel and use that for the free space tree > bitmaps. > > Signed-off-by: Omar Sandoval Applied, thanks. -- To unsubscribe from this list: send

Re: [BTRFS-PROGS][PATCH][V2] Add two new commands: 'btrfs insp physical-find' and 'btrfs insp physical-dump'

2016-07-28 Thread David Sterba
On Wed, Jul 27, 2016 at 07:43:13PM +0200, Goffredo Baroncelli wrote: > Hi all, > > the following patches add two new commands: > 1) btrfs inspect-internal physical-find > 2) btrfs inspect-internal physical-dump > > The aim of these two new commands is to locate (1) and dump (2) the stripe >

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread John Paul Adrian Glaubitz
On 07/28/2016 01:58 PM, Anatoly Pugachev wrote: > but where do I get -devel branch of btrfs-progs? > I just tried git://repo.or.cz/btrfs-progs-unstable/devel.git , but > still seeing last commit in it: glaubitz@ikarus:~/upstream/devel$ git checkout devel Branch devel set up to track remote branch

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread Anatoly Pugachev
On Thu, Jul 28, 2016 at 12:44 PM, David Sterba wrote: > On Wed, Jul 27, 2016 at 09:56:09PM +0200, David Sterba wrote: >> On Wed, Jul 27, 2016 at 04:59:27PM +0300, Anatoly Pugachev wrote: >> > Hello! >> > >> > Running xfstests suite, got in logs mkfs.btrfs bus error, debugging it

Re: [PATCH] btrfs-progs: fi defrag: change default extent target size to 32 MiB

2016-07-28 Thread David Sterba
On Thu, Jul 28, 2016 at 12:28:27PM +0100, Graham Cobb wrote: > On 28/07/16 12:17, David Sterba wrote: > > diff --git a/cmds-filesystem.c b/cmds-filesystem.c > > index ef1f550b51c0..6b381c582ea7 100644 > > --- a/cmds-filesystem.c > > +++ b/cmds-filesystem.c > > @@ -968,7 +968,7 @@ static const char

Re: [PATCH] btrfs: Change RAID stripesize to a user-configurable option

2016-07-28 Thread David Sterba
I'll comment on the overall approach and skip code-specific comments. The changelog does not explain why there's a need for a new blockgroup type and what's the relation to the existing types. It seems that it extends the data/metadata/system group, but I think this is totally wrong. The

Re: [PATCH] btrfs-progs: fi defrag: change default extent target size to 32 MiB

2016-07-28 Thread Graham Cobb
On 28/07/16 12:17, David Sterba wrote: > diff --git a/cmds-filesystem.c b/cmds-filesystem.c > index ef1f550b51c0..6b381c582ea7 100644 > --- a/cmds-filesystem.c > +++ b/cmds-filesystem.c > @@ -968,7 +968,7 @@ static const char * const cmd_filesystem_defrag_usage[] = > { > "-f

[PATCH] btrfs-progs: fi defrag: change default extent target size to 32 MiB

2016-07-28 Thread David Sterba
The kernel default is too low, 32 MiB is recommended and should give better results. Signed-off-by: David Sterba --- Documentation/btrfs-filesystem.asciidoc | 16 cmds-filesystem.c | 11 +-- 2 files changed, 21 insertions(+), 6

Re: [PATCH v3] btrfs: fix fsfreeze hang caused by delayed iputs deal

2016-07-28 Thread Wang Xiaoguang
hello, On 07/28/2016 06:22 PM, David Sterba wrote: On Thu, Jul 28, 2016 at 10:43:15AM +0800, Wang Xiaoguang wrote: When running fstests generic/068, sometimes we got below deadlock: xfs_io D 8800331dbb20 0 6697 6693 0x0080 8800331dbb20 88007acfc140

Re: btrfs fi defrag does not defrag files >256kB?

2016-07-28 Thread David Sterba
On Wed, Jul 27, 2016 at 01:19:01PM -0400, Nicholas D Steeves wrote: > > In that regard a defrag -t 32M recommendation is reasonable for a > > converted filesystem, tho you can certainly go larger... to 1 GiB as I > > said. > > I only mentioned btrfs-convert.asciidoc, because that's what led me to

Re: [PATCH v3] btrfs: fix fsfreeze hang caused by delayed iputs deal

2016-07-28 Thread David Sterba
On Thu, Jul 28, 2016 at 10:43:15AM +0800, Wang Xiaoguang wrote: > When running fstests generic/068, sometimes we got below deadlock: > xfs_io D 8800331dbb20 0 6697 6693 0x0080 > 8800331dbb20 88007acfc140 880034d895c0 8800331dc000 > 880032d243e8

Re: [PATCH] btrfs-progs: Doc: Fix format error in btrfs-send

2016-07-28 Thread David Sterba
On Thu, Jul 28, 2016 at 04:28:25PM +0800, Qu Wenruo wrote: > Signed-off-by: Qu Wenruo Applied, thanks. -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [sparc64] mkfs.btrfs bus error / align issue?

2016-07-28 Thread David Sterba
On Wed, Jul 27, 2016 at 09:56:09PM +0200, David Sterba wrote: > On Wed, Jul 27, 2016 at 04:59:27PM +0300, Anatoly Pugachev wrote: > > Hello! > > > > Running xfstests suite, got in logs mkfs.btrfs bus error, debugging it > > shows the following : > > > > Program received signal SIGBUS, Bus error.

[PATCH] btrfs-progs: Doc: Fix format error in btrfs-send

2016-07-28 Thread Qu Wenruo
Signed-off-by: Qu Wenruo --- Documentation/btrfs-send.asciidoc | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/btrfs-send.asciidoc b/Documentation/btrfs-send.asciidoc index 47b0b04..96659ee 100644 --- a/Documentation/btrfs-send.asciidoc +++

[PATCH 08/13] btrfs-progs: check: introduce function to check inode item

2016-07-28 Thread Lu Fengqi
Introduce a new function check_inode_item() to check INODE_ITEM and related ITEMs that have the same inode id. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 170 +++

[PATCH 12/13] btrfs-progs: check: fix the return value bug of cmd_check()

2016-07-28 Thread Lu Fengqi
The function cmd_check() is called by the main function of btrfs.c, its return value will be returned by exit(). Resulting in the loss of significant bits in some cases, for example this value is greater than 0377. If use a bool value "err" to store all of the return value, this will solve the

[PATCH 07/13] btrfs-progs: check: introduce function to check file extent

2016-07-28 Thread Lu Fengqi
Introduce a new function check_file_extent() to check file extent, such as datasum, hole, size. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 94 1 file

[PATCH 03/13] btrfs-progs: check: introduce function to check inode_ref

2016-07-28 Thread Lu Fengqi
Introduce a new function check_inode_ref() to check INODE_REF, and call find_dir_item() to find the related DIR_ITEM/DIR_INDEX. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 77

[PATCH 06/13] btrfs-progs: check: introduce a function to check dir_item

2016-07-28 Thread Lu Fengqi
Introduce a new function check_dir_item() to check DIR_ITEM/DIR_INDEX, and call find_inode_ref() to find the related INODE_REF/INODE_EXTREF. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 137

[PATCH 09/13] btrfs-progs: check: introduce function to check fs root

2016-07-28 Thread Lu Fengqi
Introduce a new function check_fs_root_v2() to check fs root, and call check_inode_item to check the items in the tree. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 76

[PATCH 13/13] btrfs-progs: check: fix false warning for check_extent_item()

2016-07-28 Thread Lu Fengqi
In the case that a extent doesn't have inline ref, this function shouldn't report ITEM_SIZE_MISMATCH. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git

[PATCH 11/13] btrfs-progs: check: introduce low_memory mode fs_tree check

2016-07-28 Thread Lu Fengqi
Introduce a new function check_fs_roots_v2() for check fs_tree in low_memory mode. It call check_fs_root_v2() to check fs_root, and call check_root_ref() to check root_ref. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c |

[PATCH 10/13] btrfs-progs: check: introduce function to check root ref

2016-07-28 Thread Lu Fengqi
Introduce a new function check_root_ref() to check root_ref/root_backref. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 93 1 file changed, 93 insertions(+)

[PATCH 02/13] btrfs-progs: check: introduce function to find dir_item

2016-07-28 Thread Lu Fengqi
Introduce a new function find_dir_item() to find DIR_ITEM for the given key, and check it with the specified INODE_REF/INODE_EXTREF match. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 138

[PATCH 00/13] btrfs-progs: check: check fs roots in low_memory mode

2016-07-28 Thread Lu Fengqi
This patchset implements check fs trees in low memory mode, and fix the return value bug of the function cmd_check(). Lu Fengqi (13): btrfs-progs: move btrfs_extref_hash() to hash.h btrfs-progs: check: introduce function to find dir_item btrfs-progs: check: introduce function to check

[PATCH 05/13] btrfs-progs: check: introduce function to find inode_ref

2016-07-28 Thread Lu Fengqi
Introduce a new function find_inode_ref() to find INODE_REF/INODE_EXTREF for the given key, and check it with the specified DIR_ITEM/DIR_INDEX match. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 152

[PATCH 04/13] btrfs-progs: check: introduce function to check inode_extref

2016-07-28 Thread Lu Fengqi
Introduce a new function check_inode_extref() to check INODE_EXTREF, and call find_dir_item() to find the related DIR_ITEM/DIR_INDEX. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- cmds-check.c | 79

[PATCH 01/13] btrfs-progs: move btrfs_extref_hash() to hash.h

2016-07-28 Thread Lu Fengqi
Move btrfs_extref_hash() from inode-item.c to hash.h, so that the function can be called elsewhere. Signed-off-by: Lu Fengqi Signed-off-by: Qu Wenruo --- hash.h | 10 ++ inode-item.c | 8 +--- 2 files changed, 11