All of lore.kernel.org
 help / color / mirror / Atom feed
* WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
@ 2017-12-14 11:02 Dmitrii Tcvetkov
  2017-12-14 13:21 ` Nikolay Borisov
  0 siblings, 1 reply; 9+ messages in thread
From: Dmitrii Tcvetkov @ 2017-12-14 11:02 UTC (permalink / raw)
  To: linux-btrfs

Since 4.15-rc1 if btrfs filesystem is mounted with flushoncommit mount option
then during fsync this trace appears in dmesg:

[   17.323092] WARNING: CPU: 0 PID: 364 at fs/fs-writeback.c:2339 __writeback_inodes_sb_nr+0xbf/0xd0
[   17.323925] Modules linked in:
[   17.324697] CPU: 0 PID: 364 Comm: systemd-journal Not tainted 4.15.0-rc3 #2
[   17.325424] Hardware name: To be filled by O.E.M. To be filled by O.E.M./SABERTOOTH 990FX R2.0, BIOS 2901 05/04/2016
[   17.326177] RIP: 0010:__writeback_inodes_sb_nr+0xbf/0xd0
[   17.326875] RSP: 0018:ffff8bcd40a77d08 EFLAGS: 00010246
[   17.327598] RAX: 0000000000000000 RBX: ffff8a3fa9764488 RCX: 0000000000000000
[   17.328321] RDX: 0000000000000002 RSI: 00000000000018ae RDI: ffff8a3fa96c7070
[   17.329012] RBP: ffff8bcd40a77d0c R08: ffffffffffffff80 R09: 00000000000000ff
[   17.329740] R10: ffff8bcd40a77c10 R11: 0000000000001000 R12: 0000000000000000
[   17.330439] R13: ffff8a3fa915e698 R14: ffff8a3fb04ed780 R15: ffff8a3fa9a16610
[   17.331169] FS:  00007f72d53338c0(0000) GS:ffff8a3fbec00000(0000) knlGS:0000000000000000
[   17.331880] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   17.332624] CR2: 00007f72d09a5000 CR3: 0000000329334000 CR4: 00000000000406f0
[   17.333383] Call Trace:
[   17.334113]  btrfs_commit_transaction+0x857/0x920
[   17.334874]  btrfs_sync_file+0x30c/0x3e0
[   17.335622]  do_fsync+0x33/0x60
[   17.336332]  SyS_fsync+0x7/0x10
[   17.337069]  do_syscall_64+0x63/0x360
[   17.337776]  entry_SYSCALL64_slow_path+0x25/0x25
[   17.338513] RIP: 0033:0x7f72d4f29094
[   17.339244] RSP: 002b:00007ffd71b078f8 EFLAGS: 00000246 ORIG_RAX: 000000000000004a
[   17.339962] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f72d4f29094
[   17.340718] RDX: 0000000000090000 RSI: 00005630b6f8b090 RDI: 0000000000000010
[   17.341431] RBP: 00005630b6f8b090 R08: 00000000000fffff R09: 0000000000000000
[   17.342169] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000010
[   17.342902] R13: 00005630b6f88f60 R14: 0000000000000001 R15: 0000000000000001
[   17.343604] Code: df 0f b6 d1 e8 a3 fc ff ff 48 89 ee 48 89 df e8 78 f5 ff
ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 0b 48 83 c4 50 5b 5d c3 <0f> ff
eb ca e8 38 1e ec ff 0f 1f 84 00 00 00 00 00 41 54 55 48
[   17.344408] ---[ end trace ff4cf41ec70ec0a7 ]---

If fs mounted without flushoncommit then no warnings. Other mount options don't influence the behaviour.

Steps to reproduce:
mkfs.btrfs <block device>
mount -o flushoncommit <block device> <mountpoint>
echo test > <mountpoint>/test 
btrfs filesystem sync <mountpoint>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2017-12-14 11:02 WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit Dmitrii Tcvetkov
@ 2017-12-14 13:21 ` Nikolay Borisov
  2017-12-14 13:38   ` David Sterba
  2017-12-14 15:05   ` Dmitrii Tcvetkov
  0 siblings, 2 replies; 9+ messages in thread
From: Nikolay Borisov @ 2017-12-14 13:21 UTC (permalink / raw)
  To: Dmitrii Tcvetkov, linux-btrfs



On 14.12.2017 13:02, Dmitrii Tcvetkov wrote:
> Since 4.15-rc1 if btrfs filesystem is mounted with flushoncommit mount option
> then during fsync this trace appears in dmesg:
> 
> [   17.323092] WARNING: CPU: 0 PID: 364 at fs/fs-writeback.c:2339 __writeback_inodes_sb_nr+0xbf/0xd0
> [   17.323925] Modules linked in:
> [   17.324697] CPU: 0 PID: 364 Comm: systemd-journal Not tainted 4.15.0-rc3 #2
> [   17.325424] Hardware name: To be filled by O.E.M. To be filled by O.E.M./SABERTOOTH 990FX R2.0, BIOS 2901 05/04/2016
> [   17.326177] RIP: 0010:__writeback_inodes_sb_nr+0xbf/0xd0
> [   17.326875] RSP: 0018:ffff8bcd40a77d08 EFLAGS: 00010246
> [   17.327598] RAX: 0000000000000000 RBX: ffff8a3fa9764488 RCX: 0000000000000000
> [   17.328321] RDX: 0000000000000002 RSI: 00000000000018ae RDI: ffff8a3fa96c7070
> [   17.329012] RBP: ffff8bcd40a77d0c R08: ffffffffffffff80 R09: 00000000000000ff
> [   17.329740] R10: ffff8bcd40a77c10 R11: 0000000000001000 R12: 0000000000000000
> [   17.330439] R13: ffff8a3fa915e698 R14: ffff8a3fb04ed780 R15: ffff8a3fa9a16610
> [   17.331169] FS:  00007f72d53338c0(0000) GS:ffff8a3fbec00000(0000) knlGS:0000000000000000
> [   17.331880] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
> [   17.332624] CR2: 00007f72d09a5000 CR3: 0000000329334000 CR4: 00000000000406f0
> [   17.333383] Call Trace:
> [   17.334113]  btrfs_commit_transaction+0x857/0x920
> [   17.334874]  btrfs_sync_file+0x30c/0x3e0
> [   17.335622]  do_fsync+0x33/0x60
> [   17.336332]  SyS_fsync+0x7/0x10
> [   17.337069]  do_syscall_64+0x63/0x360
> [   17.337776]  entry_SYSCALL64_slow_path+0x25/0x25
> [   17.338513] RIP: 0033:0x7f72d4f29094
> [   17.339244] RSP: 002b:00007ffd71b078f8 EFLAGS: 00000246 ORIG_RAX: 000000000000004a
> [   17.339962] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f72d4f29094
> [   17.340718] RDX: 0000000000090000 RSI: 00005630b6f8b090 RDI: 0000000000000010
> [   17.341431] RBP: 00005630b6f8b090 R08: 00000000000fffff R09: 0000000000000000
> [   17.342169] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000010
> [   17.342902] R13: 00005630b6f88f60 R14: 0000000000000001 R15: 0000000000000001
> [   17.343604] Code: df 0f b6 d1 e8 a3 fc ff ff 48 89 ee 48 89 df e8 78 f5 ff
> ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 0b 48 83 c4 50 5b 5d c3 <0f> ff
> eb ca e8 38 1e ec ff 0f 1f 84 00 00 00 00 00 41 54 55 48
> [   17.344408] ---[ end trace ff4cf41ec70ec0a7 ]---

So this is due to writeback_inodes_sb being called without holding
s_umount. So 4.15-rc1 the first kernel that started exhibiting this or
did you also see it with earlier kernel

> 
> If fs mounted without flushoncommit then no warnings. Other mount options don't influence the behaviour.
> 
> Steps to reproduce:
> mkfs.btrfs <block device>
> mount -o flushoncommit <block device> <mountpoint>
> echo test > <mountpoint>/test 
> btrfs filesystem sync <mountpoint>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2017-12-14 13:21 ` Nikolay Borisov
@ 2017-12-14 13:38   ` David Sterba
  2017-12-14 15:05   ` Dmitrii Tcvetkov
  1 sibling, 0 replies; 9+ messages in thread
From: David Sterba @ 2017-12-14 13:38 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: Dmitrii Tcvetkov, linux-btrfs, jbacik

On Thu, Dec 14, 2017 at 03:21:52PM +0200, Nikolay Borisov wrote:
> 
> 
> On 14.12.2017 13:02, Dmitrii Tcvetkov wrote:
> > Since 4.15-rc1 if btrfs filesystem is mounted with flushoncommit mount option
> > then during fsync this trace appears in dmesg:
> > 
> > [   17.323092] WARNING: CPU: 0 PID: 364 at fs/fs-writeback.c:2339 __writeback_inodes_sb_nr+0xbf/0xd0
> > [   17.323925] Modules linked in:
> > [   17.324697] CPU: 0 PID: 364 Comm: systemd-journal Not tainted 4.15.0-rc3 #2
> > [   17.325424] Hardware name: To be filled by O.E.M. To be filled by O.E.M./SABERTOOTH 990FX R2.0, BIOS 2901 05/04/2016
> > [   17.326177] RIP: 0010:__writeback_inodes_sb_nr+0xbf/0xd0
> > [   17.326875] RSP: 0018:ffff8bcd40a77d08 EFLAGS: 00010246
> > [   17.327598] RAX: 0000000000000000 RBX: ffff8a3fa9764488 RCX: 0000000000000000
> > [   17.328321] RDX: 0000000000000002 RSI: 00000000000018ae RDI: ffff8a3fa96c7070
> > [   17.329012] RBP: ffff8bcd40a77d0c R08: ffffffffffffff80 R09: 00000000000000ff
> > [   17.329740] R10: ffff8bcd40a77c10 R11: 0000000000001000 R12: 0000000000000000
> > [   17.330439] R13: ffff8a3fa915e698 R14: ffff8a3fb04ed780 R15: ffff8a3fa9a16610
> > [   17.331169] FS:  00007f72d53338c0(0000) GS:ffff8a3fbec00000(0000) knlGS:0000000000000000
> > [   17.331880] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
> > [   17.332624] CR2: 00007f72d09a5000 CR3: 0000000329334000 CR4: 00000000000406f0
> > [   17.333383] Call Trace:
> > [   17.334113]  btrfs_commit_transaction+0x857/0x920
> > [   17.334874]  btrfs_sync_file+0x30c/0x3e0
> > [   17.335622]  do_fsync+0x33/0x60
> > [   17.336332]  SyS_fsync+0x7/0x10
> > [   17.337069]  do_syscall_64+0x63/0x360
> > [   17.337776]  entry_SYSCALL64_slow_path+0x25/0x25
> > [   17.338513] RIP: 0033:0x7f72d4f29094
> > [   17.339244] RSP: 002b:00007ffd71b078f8 EFLAGS: 00000246 ORIG_RAX: 000000000000004a
> > [   17.339962] RAX: ffffffffffffffda RBX: 0000000000000000 RCX: 00007f72d4f29094
> > [   17.340718] RDX: 0000000000090000 RSI: 00005630b6f8b090 RDI: 0000000000000010
> > [   17.341431] RBP: 00005630b6f8b090 R08: 00000000000fffff R09: 0000000000000000
> > [   17.342169] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000010
> > [   17.342902] R13: 00005630b6f88f60 R14: 0000000000000001 R15: 0000000000000001
> > [   17.343604] Code: df 0f b6 d1 e8 a3 fc ff ff 48 89 ee 48 89 df e8 78 f5 ff
> > ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 0b 48 83 c4 50 5b 5d c3 <0f> ff
> > eb ca e8 38 1e ec ff 0f 1f 84 00 00 00 00 00 41 54 55 48
> > [   17.344408] ---[ end trace ff4cf41ec70ec0a7 ]---
> 
> So this is due to writeback_inodes_sb being called without holding
> s_umount. So 4.15-rc1 the first kernel that started exhibiting this or
> did you also see it with earlier kernel

This is new in 4.15, there was an earlier report
https://marc.info/?l=linux-btrfs&m=151315564008773

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2017-12-14 13:21 ` Nikolay Borisov
  2017-12-14 13:38   ` David Sterba
@ 2017-12-14 15:05   ` Dmitrii Tcvetkov
  1 sibling, 0 replies; 9+ messages in thread
From: Dmitrii Tcvetkov @ 2017-12-14 15:05 UTC (permalink / raw)
  To: Nikolay Borisov; +Cc: linux-btrfs

On Thu, 14 Dec 2017 15:21:52 +0200
Nikolay Borisov <nborisov@suse.com> wrote:

> On 14.12.2017 13:02, Dmitrii Tcvetkov wrote:
> > Since 4.15-rc1 if btrfs filesystem is mounted with flushoncommit mount
> > option then during fsync this trace appears in dmesg:
> > 
> > [   17.323092] WARNING: CPU: 0 PID: 364 at fs/fs-writeback.c:2339
> > __writeback_inodes_sb_nr+0xbf/0xd0 [   17.323925] Modules linked in:
> > [   17.324697] CPU: 0 PID: 364 Comm: systemd-journal Not tainted 4.15.0-rc3
> > #2 [   17.325424] Hardware name: To be filled by O.E.M. To be filled by
> > O.E.M./SABERTOOTH 990FX R2.0, BIOS 2901 05/04/2016 [   17.326177] RIP:
> > 0010:__writeback_inodes_sb_nr+0xbf/0xd0 [   17.326875] RSP:
> > 0018:ffff8bcd40a77d08 EFLAGS: 00010246 [   17.327598] RAX: 0000000000000000
> > RBX: ffff8a3fa9764488 RCX: 0000000000000000 [   17.328321] RDX:
> > 0000000000000002 RSI: 00000000000018ae RDI: ffff8a3fa96c7070 [   17.329012]
> > RBP: ffff8bcd40a77d0c R08: ffffffffffffff80 R09: 00000000000000ff
> > [   17.329740] R10: ffff8bcd40a77c10 R11: 0000000000001000 R12:
> > 0000000000000000 [   17.330439] R13: ffff8a3fa915e698 R14: ffff8a3fb04ed780
> > R15: ffff8a3fa9a16610 [   17.331169] FS:  00007f72d53338c0(0000)
> > GS:ffff8a3fbec00000(0000) knlGS:0000000000000000 [   17.331880] CS:  0010
> > DS: 0000 ES: 0000 CR0: 0000000080050033 [   17.332624] CR2:
> > 00007f72d09a5000 CR3: 0000000329334000 CR4: 00000000000406f0 [   17.333383]
> > Call Trace: [   17.334113]  btrfs_commit_transaction+0x857/0x920
> > [   17.334874]  btrfs_sync_file+0x30c/0x3e0 [   17.335622]
> > do_fsync+0x33/0x60 [   17.336332]  SyS_fsync+0x7/0x10
> > [   17.337069]  do_syscall_64+0x63/0x360
> > [   17.337776]  entry_SYSCALL64_slow_path+0x25/0x25
> > [   17.338513] RIP: 0033:0x7f72d4f29094
> > [   17.339244] RSP: 002b:00007ffd71b078f8 EFLAGS: 00000246 ORIG_RAX:
> > 000000000000004a [   17.339962] RAX: ffffffffffffffda RBX: 0000000000000000
> > RCX: 00007f72d4f29094 [   17.340718] RDX: 0000000000090000 RSI:
> > 00005630b6f8b090 RDI: 0000000000000010 [   17.341431] RBP: 00005630b6f8b090
> > R08: 00000000000fffff R09: 0000000000000000 [   17.342169] R10:
> > 0000000000000000 R11: 0000000000000246 R12: 0000000000000010 [   17.342902]
> > R13: 00005630b6f88f60 R14: 0000000000000001 R15: 0000000000000001
> > [   17.343604] Code: df 0f b6 d1 e8 a3 fc ff ff 48 89 ee 48 89 df e8 78 f5
> > ff ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 0b 48 83 c4 50 5b 5d c3
> > <0f> ff eb ca e8 38 1e ec ff 0f 1f 84 00 00 00 00 00 41 54 55 48
> > [   17.344408] ---[ end trace ff4cf41ec70ec0a7 ]---  
> 
> So this is due to writeback_inodes_sb being called without holding
> s_umount. So 4.15-rc1 the first kernel that started exhibiting this or
> did you also see it with earlier kernel
>

I didn't test kernels during merge window, the behavior was since 4.15-rc1 and
it's relevant until current mainline. Can't reproduce on 4.14 and earlier.



^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2022-10-24 21:23     ` Roman Mamedov
@ 2022-11-04 13:02       ` David Sterba
  0 siblings, 0 replies; 9+ messages in thread
From: David Sterba @ 2022-11-04 13:02 UTC (permalink / raw)
  To: Roman Mamedov; +Cc: linux-btrfs

On Tue, Oct 25, 2022 at 02:23:43AM +0500, Roman Mamedov wrote:
> On Mon, 24 Oct 2022 16:16:29 +0200
> David Sterba <dsterba@suse.cz> wrote:
> 
> > > But not backported to stable series, why not? Seems to be a small and simple
> > > fix.
> > 
> > 5.10 may still be a reasonable target for backport. It does not apply
> > cleanly and the 5.10 version tries to do some flushing of subvolume
> > trees, which was removed later on, there may be some dependencies too.
> 
> Sorry I meant the longterm series. The issue was reported starting with
> 4.15-rc1, so of these also 4.19 and 5.4 will be affected. Sure, those may or
> may not be as important or feasible for a backport, but at least 5.10
> hopefully is, as it is the current long-longterm supported until 2026 per the
> Releases page on kernel.org, 3 years further than 5.15.

Checking changes related to btrfs_start_delalloc_flush, 5.10 is doable,
there are correctness fixes that landed in 5.7 and there are like 2-3
patches that would have to be backported.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2022-10-24 14:16   ` David Sterba
@ 2022-10-24 21:23     ` Roman Mamedov
  2022-11-04 13:02       ` David Sterba
  0 siblings, 1 reply; 9+ messages in thread
From: Roman Mamedov @ 2022-10-24 21:23 UTC (permalink / raw)
  To: David Sterba; +Cc: linux-btrfs

On Mon, 24 Oct 2022 16:16:29 +0200
David Sterba <dsterba@suse.cz> wrote:

> > But not backported to stable series, why not? Seems to be a small and simple
> > fix.
> 
> 5.10 may still be a reasonable target for backport. It does not apply
> cleanly and the 5.10 version tries to do some flushing of subvolume
> trees, which was removed later on, there may be some dependencies too.

Sorry I meant the longterm series. The issue was reported starting with
4.15-rc1, so of these also 4.19 and 5.4 will be affected. Sure, those may or
may not be as important or feasible for a backport, but at least 5.10
hopefully is, as it is the current long-longterm supported until 2026 per the
Releases page on kernel.org, 3 years further than 5.15.

-- 
With respect,
Roman

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2022-10-24  7:37 ` Roman Mamedov
@ 2022-10-24 14:16   ` David Sterba
  2022-10-24 21:23     ` Roman Mamedov
  0 siblings, 1 reply; 9+ messages in thread
From: David Sterba @ 2022-10-24 14:16 UTC (permalink / raw)
  To: Roman Mamedov; +Cc: linux-btrfs

On Mon, Oct 24, 2022 at 12:37:46PM +0500, Roman Mamedov wrote:
> On Mon, 24 Oct 2022 04:17:13 +0500
> Roman Mamedov <rm@romanrm.net> wrote:
> 
> > Hello,
> > 
> > Just wanted to report that I still get the same warning with flushoncommit as
> > someone posted[1][2] back in 2017, also today on kernel 5.10.149. Was that
> > supposed to be fixed? Or maybe fixed in 6.0+?
> > 
> > Thanks
> > 
> > [1] https://www.spinics.net/lists/linux-btrfs/msg72483.html
> > [2] https://marc.info/?l=linux-btrfs&m=151315564008773
> 
> I found that this might have been fixed:
> https://lore.kernel.org/linux-btrfs/20220208224129.GI12643@twin.jikos.cz/

It's mentioned at https://btrfs.readthedocs.io/en/latest/Feature-by-version.html

and "Also backported to 5.15.27 and 5.16.13".

> But not backported to stable series, why not? Seems to be a small and simple
> fix.

5.10 may still be a reasonable target for backport. It does not apply
cleanly and the 5.10 version tries to do some flushing of subvolume
trees, which was removed later on, there may be some dependencies too.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
  2022-10-23 23:17 Roman Mamedov
@ 2022-10-24  7:37 ` Roman Mamedov
  2022-10-24 14:16   ` David Sterba
  0 siblings, 1 reply; 9+ messages in thread
From: Roman Mamedov @ 2022-10-24  7:37 UTC (permalink / raw)
  To: linux-btrfs

On Mon, 24 Oct 2022 04:17:13 +0500
Roman Mamedov <rm@romanrm.net> wrote:

> Hello,
> 
> Just wanted to report that I still get the same warning with flushoncommit as
> someone posted[1][2] back in 2017, also today on kernel 5.10.149. Was that
> supposed to be fixed? Or maybe fixed in 6.0+?
> 
> Thanks
> 
> [1] https://www.spinics.net/lists/linux-btrfs/msg72483.html
> [2] https://marc.info/?l=linux-btrfs&m=151315564008773

I found that this might have been fixed:
https://lore.kernel.org/linux-btrfs/20220208224129.GI12643@twin.jikos.cz/

But not backported to stable series, why not? Seems to be a small and simple
fix.

> [Mon Oct 24 03:49:18 2022] WARNING: CPU: 9 PID: 8883 at fs/fs-writeback.c:2456 __writeback_inodes_sb_nr+0xba/0xd0
> [Mon Oct 24 03:49:18 2022] Modules linked in: dm_snapshot(E) nls_ascii(E) nls_cp437(E) vfat(E) fat(E) uas(E) usb_storage(E) xt_set(E) ip_set_hash_net(E) ip_set(E) nfnetlink(E) veth(E) vhost_net(E) vhost(E) vhost_iotlb(E) tap(E) tun(E) i2c_dev(E) sit(E) tunnel4(E) ip_tunnel(E) xt_comment(E) xt_multiport(E) xt_limit(E) xt_length(E) xt_CT(E) xt_tcpudp(E) xt_state(E) xt_conntrack(E) ip6t_rpfilter(E) ipt_rpfilter(E) ip6table_nat(E) ip6table_raw(E) ip6table_mangle(E) iptable_nat(E) nf_nat(E) nf_conntrack(E) nf_defrag_ipv6(E) nf_defrag_ipv4(E) iptable_raw(E) iptable_mangle(E) ip6table_filter(E) ip6_tables(E) iptable_filter(E) ip_tables(E) x_tables(E) cpufreq_userspace(E) cpufreq_conservative(E) cpufreq_ondemand(E) cpufreq_powersave(E) fuse(E) nbd(E) 8021q(E) garp(E) mrp(E) bridge(E) stp(E) llc(E) tcp_bbr(E) xfs(E) dm_thin_pool(E) crc32_generic(E) loop(E) radeon(E) edac_mce_amd(E) kvm_amd(E) ttm(E) drm_kms_helper(E) kvm(E) cec(E) drm(E) snd_pcsp(E) i2c_algo_bit(E) irqbypass(E) snd_pcm(E) e
 vd
>  ev(E) cp210x(E)
> [Mon Oct 24 03:49:18 2022]  rapl(E) joydev(E) snd_timer(E) usbserial(E) snd(E) sg(E) wmi_bmof(E) soundcore(E) sp5100_tco(E) ccp(E) watchdog(E) rng_core(E) k10temp(E) acpi_cpufreq(E) button(E) ext4(E) crc16(E) mbcache(E) jbd2(E) btrfs(E) blake2b_generic(E) dm_crypt(E) raid10(E) raid456(E) async_raid6_recov(E) async_memcpy(E) async_pq(E) async_xor(E) async_tx(E) xor(E) raid6_pq(E) raid0(E) multipath(E) linear(E) dm_cache_smq(E) dm_cache(E) dm_persistent_data(E) dm_bio_prison(E) dm_bufio(E) dm_mod(E) libcrc32c(E) crc32c_generic(E) sd_mod(E) hid_generic(E) usbhid(E) hid(E) raid1(E) r8169(E) ahci(E) crc32_pclmul(E) realtek(E) libahci(E) crc32c_intel(E) md_mod(E) ghash_clmulni_intel(E) xhci_pci(E) aesni_intel(E) libaes(E) crypto_simd(E) cryptd(E) glue_helper(E) mdio_devres(E) nvme(E) libata(E) i2c_piix4(E) xhci_hcd(E) libphy(E) nvme_core(E) t10_pi(E) scsi_mod(E) usbcore(E) crc_t10dif(E) usb_common(E) crct10dif_generic(E) crct10dif_pclmul(E) crct10dif_common(E) wmi(E) gpio_amdpt(E) gpio_g
 en
>  eric(E)
> [Mon Oct 24 03:49:18 2022] CPU: 9 PID: 8883 Comm: btrfs-transacti Tainted: G        W   E     5.10.149-rm1+ #308
> [Mon Oct 24 03:49:18 2022] Hardware name: To Be Filled By O.E.M. To Be Filled By O.E.M./B550 PG Velocita, BIOS P2.10 08/04/2021
> [Mon Oct 24 03:49:18 2022] RIP: 0010:__writeback_inodes_sb_nr+0xba/0xd0
> [Mon Oct 24 03:49:18 2022] Code: c7 0f b6 d1 e8 47 fc ff ff 48 89 e7 e8 bf fb ff ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 11 48 83 c4 50 c3 cc cc cc cc <0f> 0b 0f 1f 40 00 eb c7 e8 e9 7e 59 00 66 0f 1f 84 00 00 00 00 00
> [Mon Oct 24 03:49:18 2022] RSP: 0018:ffffba9303a3be00 EFLAGS: 00010246
> [Mon Oct 24 03:49:18 2022] RAX: ffff95c0e044dc00 RBX: ffff95bc04f4f340 RCX: 0000000000000000
> [Mon Oct 24 03:49:18 2022] RDX: 0000000000000000 RSI: 0000000000088d13 RDI: ffff95bd2556b000
> [Mon Oct 24 03:49:18 2022] RBP: ffff95bd011e0000 R08: ffff95c0e044df58 R09: 000000000000001f
> [Mon Oct 24 03:49:18 2022] R10: 000000000000003c R11: 0000000000000000 R12: ffff95c022220e00
> [Mon Oct 24 03:49:18 2022] R13: ffff95bd011e0460 R14: ffff95bd011e0488 R15: ffff95bd2556c000
> [Mon Oct 24 03:49:18 2022] FS:  0000000000000000(0000) GS:ffff95cbfec40000(0000) knlGS:0000000000000000
> [Mon Oct 24 03:49:18 2022] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
> [Mon Oct 24 03:49:18 2022] CR2: fffffa8000048000 CR3: 000000035f8ba000 CR4: 0000000000750ee0
> [Mon Oct 24 03:49:18 2022] PKRU: 55555554
> [Mon Oct 24 03:49:18 2022] Call Trace:
> [Mon Oct 24 03:49:18 2022]  btrfs_commit_transaction+0x39c/0xb80 [btrfs]
> [Mon Oct 24 03:49:18 2022]  ? start_transaction+0xe8/0x5b0 [btrfs]
> [Mon Oct 24 03:49:18 2022]  transaction_kthread+0x163/0x180 [btrfs]
> [Mon Oct 24 03:49:18 2022]  ? btrfs_cleanup_transaction+0x580/0x580 [btrfs]
> [Mon Oct 24 03:49:18 2022]  kthread+0x117/0x130
> [Mon Oct 24 03:49:18 2022]  ? __kthread_cancel_work+0x50/0x50
> [Mon Oct 24 03:49:18 2022]  ret_from_fork+0x22/0x30
> [Mon Oct 24 03:49:18 2022] ---[ end trace 88a48b38d299109e ]---
> 


-- 
With respect,
Roman

^ permalink raw reply	[flat|nested] 9+ messages in thread

* WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit
@ 2022-10-23 23:17 Roman Mamedov
  2022-10-24  7:37 ` Roman Mamedov
  0 siblings, 1 reply; 9+ messages in thread
From: Roman Mamedov @ 2022-10-23 23:17 UTC (permalink / raw)
  To: linux-btrfs

Hello,

Just wanted to report that I still get the same warning with flushoncommit as
someone posted[1][2] back in 2017, also today on kernel 5.10.149. Was that
supposed to be fixed? Or maybe fixed in 6.0+?

Thanks

[1] https://www.spinics.net/lists/linux-btrfs/msg72483.html
[2] https://marc.info/?l=linux-btrfs&m=151315564008773

[Mon Oct 24 03:49:18 2022] WARNING: CPU: 9 PID: 8883 at fs/fs-writeback.c:2456 __writeback_inodes_sb_nr+0xba/0xd0
[Mon Oct 24 03:49:18 2022] Modules linked in: dm_snapshot(E) nls_ascii(E) nls_cp437(E) vfat(E) fat(E) uas(E) usb_storage(E) xt_set(E) ip_set_hash_net(E) ip_set(E) nfnetlink(E) veth(E) vhost_net(E) vhost(E) vhost_iotlb(E) tap(E) tun(E) i2c_dev(E) sit(E) tunnel4(E) ip_tunnel(E) xt_comment(E) xt_multiport(E) xt_limit(E) xt_length(E) xt_CT(E) xt_tcpudp(E) xt_state(E) xt_conntrack(E) ip6t_rpfilter(E) ipt_rpfilter(E) ip6table_nat(E) ip6table_raw(E) ip6table_mangle(E) iptable_nat(E) nf_nat(E) nf_conntrack(E) nf_defrag_ipv6(E) nf_defrag_ipv4(E) iptable_raw(E) iptable_mangle(E) ip6table_filter(E) ip6_tables(E) iptable_filter(E) ip_tables(E) x_tables(E) cpufreq_userspace(E) cpufreq_conservative(E) cpufreq_ondemand(E) cpufreq_powersave(E) fuse(E) nbd(E) 8021q(E) garp(E) mrp(E) bridge(E) stp(E) llc(E) tcp_bbr(E) xfs(E) dm_thin_pool(E) crc32_generic(E) loop(E) radeon(E) edac_mce_amd(E) kvm_amd(E) ttm(E) drm_kms_helper(E) kvm(E) cec(E) drm(E) snd_pcsp(E) i2c_algo_bit(E) irqbypass(E) snd_pcm(E) evd
 ev(E) cp210x(E)
[Mon Oct 24 03:49:18 2022]  rapl(E) joydev(E) snd_timer(E) usbserial(E) snd(E) sg(E) wmi_bmof(E) soundcore(E) sp5100_tco(E) ccp(E) watchdog(E) rng_core(E) k10temp(E) acpi_cpufreq(E) button(E) ext4(E) crc16(E) mbcache(E) jbd2(E) btrfs(E) blake2b_generic(E) dm_crypt(E) raid10(E) raid456(E) async_raid6_recov(E) async_memcpy(E) async_pq(E) async_xor(E) async_tx(E) xor(E) raid6_pq(E) raid0(E) multipath(E) linear(E) dm_cache_smq(E) dm_cache(E) dm_persistent_data(E) dm_bio_prison(E) dm_bufio(E) dm_mod(E) libcrc32c(E) crc32c_generic(E) sd_mod(E) hid_generic(E) usbhid(E) hid(E) raid1(E) r8169(E) ahci(E) crc32_pclmul(E) realtek(E) libahci(E) crc32c_intel(E) md_mod(E) ghash_clmulni_intel(E) xhci_pci(E) aesni_intel(E) libaes(E) crypto_simd(E) cryptd(E) glue_helper(E) mdio_devres(E) nvme(E) libata(E) i2c_piix4(E) xhci_hcd(E) libphy(E) nvme_core(E) t10_pi(E) scsi_mod(E) usbcore(E) crc_t10dif(E) usb_common(E) crct10dif_generic(E) crct10dif_pclmul(E) crct10dif_common(E) wmi(E) gpio_amdpt(E) gpio_gen
 eric(E)
[Mon Oct 24 03:49:18 2022] CPU: 9 PID: 8883 Comm: btrfs-transacti Tainted: G        W   E     5.10.149-rm1+ #308
[Mon Oct 24 03:49:18 2022] Hardware name: To Be Filled By O.E.M. To Be Filled By O.E.M./B550 PG Velocita, BIOS P2.10 08/04/2021
[Mon Oct 24 03:49:18 2022] RIP: 0010:__writeback_inodes_sb_nr+0xba/0xd0
[Mon Oct 24 03:49:18 2022] Code: c7 0f b6 d1 e8 47 fc ff ff 48 89 e7 e8 bf fb ff ff 48 8b 44 24 48 65 48 33 04 25 28 00 00 00 75 11 48 83 c4 50 c3 cc cc cc cc <0f> 0b 0f 1f 40 00 eb c7 e8 e9 7e 59 00 66 0f 1f 84 00 00 00 00 00
[Mon Oct 24 03:49:18 2022] RSP: 0018:ffffba9303a3be00 EFLAGS: 00010246
[Mon Oct 24 03:49:18 2022] RAX: ffff95c0e044dc00 RBX: ffff95bc04f4f340 RCX: 0000000000000000
[Mon Oct 24 03:49:18 2022] RDX: 0000000000000000 RSI: 0000000000088d13 RDI: ffff95bd2556b000
[Mon Oct 24 03:49:18 2022] RBP: ffff95bd011e0000 R08: ffff95c0e044df58 R09: 000000000000001f
[Mon Oct 24 03:49:18 2022] R10: 000000000000003c R11: 0000000000000000 R12: ffff95c022220e00
[Mon Oct 24 03:49:18 2022] R13: ffff95bd011e0460 R14: ffff95bd011e0488 R15: ffff95bd2556c000
[Mon Oct 24 03:49:18 2022] FS:  0000000000000000(0000) GS:ffff95cbfec40000(0000) knlGS:0000000000000000
[Mon Oct 24 03:49:18 2022] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[Mon Oct 24 03:49:18 2022] CR2: fffffa8000048000 CR3: 000000035f8ba000 CR4: 0000000000750ee0
[Mon Oct 24 03:49:18 2022] PKRU: 55555554
[Mon Oct 24 03:49:18 2022] Call Trace:
[Mon Oct 24 03:49:18 2022]  btrfs_commit_transaction+0x39c/0xb80 [btrfs]
[Mon Oct 24 03:49:18 2022]  ? start_transaction+0xe8/0x5b0 [btrfs]
[Mon Oct 24 03:49:18 2022]  transaction_kthread+0x163/0x180 [btrfs]
[Mon Oct 24 03:49:18 2022]  ? btrfs_cleanup_transaction+0x580/0x580 [btrfs]
[Mon Oct 24 03:49:18 2022]  kthread+0x117/0x130
[Mon Oct 24 03:49:18 2022]  ? __kthread_cancel_work+0x50/0x50
[Mon Oct 24 03:49:18 2022]  ret_from_fork+0x22/0x30
[Mon Oct 24 03:49:18 2022] ---[ end trace 88a48b38d299109e ]---

-- 
With respect,
Roman

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-11-04 13:02 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-14 11:02 WARN_ON in __writeback_inodes_sb_nr when btrfs mounted with flushoncommit Dmitrii Tcvetkov
2017-12-14 13:21 ` Nikolay Borisov
2017-12-14 13:38   ` David Sterba
2017-12-14 15:05   ` Dmitrii Tcvetkov
2022-10-23 23:17 Roman Mamedov
2022-10-24  7:37 ` Roman Mamedov
2022-10-24 14:16   ` David Sterba
2022-10-24 21:23     ` Roman Mamedov
2022-11-04 13:02       ` David Sterba

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.