Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-04-13 Thread Wang Yugui
Hi, This patch works. From:Dennis Zhou To: Wang Yugui Cc: Vlastimil Babka , linux...@kvack.org, linux-btrfs@vger.kernel.org Date:Thu, 8 Apr 2021 13:48:33 + Subject: Re: unexpected -ENOMEM from percpu_counter_init() Ah. Can you try the followi

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-04-13 Thread Martin Raiber
On 30.03.2021 09:16 Wang Yugui wrote: H, On 30.03.21 г. 9:24, Wang Yugui wrote: Hi, Nikolay Borisov With a lot of dump_stack()/printk inserted around ENOMEM in btrfs code, we find out the call stack for ENOMEM. see the file -btrfs-dump_stack-when-ENOMEM.patch #cat /usr/hpc-bio/xfstests/

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-30 Thread Wang Yugui
H, > On 30.03.21 г. 9:24, Wang Yugui wrote: > > Hi, Nikolay Borisov > > > > With a lot of dump_stack()/printk inserted around ENOMEM in btrfs code, > > we find out the call stack for ENOMEM. > > see the file -btrfs-dump_stack-when-ENOMEM.patch > > > > > > #cat /usr/hpc-bio/xfstests/results/

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-29 Thread Nikolay Borisov
On 30.03.21 г. 9:24, Wang Yugui wrote: > Hi, Nikolay Borisov > > With a lot of dump_stack()/printk inserted around ENOMEM in btrfs code, > we find out the call stack for ENOMEM. > see the file -btrfs-dump_stack-when-ENOMEM.patch > > > #cat /usr/hpc-bio/xfstests/results//generic/476.dmesg

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-28 Thread Wang Yugui
Hi, > kmem_cache_zalloc() without __GFP_NOFAIL may fail. > > btrfs use kmem_cache_zalloc() with GFP_NOFS mostly, > and only few place with __GFP_NOFAIL. > > xfs use kmem_cache_zalloc() with __GFP_NOFAIL mostly. > > It is very difficult to test all case of failure in kmem_cache_zalloc() . > >

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-27 Thread Wang Yugui
Hi, kmem_cache_zalloc() without __GFP_NOFAIL may fail. btrfs use kmem_cache_zalloc() with GFP_NOFS mostly, and only few place with __GFP_NOFAIL. xfs use kmem_cache_zalloc() with __GFP_NOFAIL mostly. It is very difficult to test all case of failure in kmem_cache_zalloc() . Should btrfs use kme

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-27 Thread Wang Yugui
Hi, these callstack have a same root failure. struct btrfs_path *btrfs_alloc_path(void) { return kmem_cache_zalloc(btrfs_path_cachep, GFP_NOFS); } fs/btrfs/transaction.c:1679 create_pending_snapshot+0xc1a/0xda0 [btrfs] (fail)new_root = btrfs_get_new_fs_root(fs_info, objectid, anon_dev

Re: xfstests generic/476 failed on btrfs(errno=-12 Out of memory, kernel 5.11.10)

2021-03-27 Thread Wang Yugui
Hi, SSD/SAS is easy than SSD/NVMe to reproduce this problem. Yet not able to reproduce this problem on another server. CPU: Xeon(R) CPU E5-2680 v2(10 core) *2 memory: 192G, no swap disk: SSD/NVMe with same partition size as SSD/SAS. And this problem happened in kernel 5.10.26 + btrfs backpor