代码拉取完成,页面将自动刷新
ext4 continue模式下,extent落盘失败+extent cache回收可能导致后续覆盖写相同文件触发块分配流程使用预分配块的BUGON
[ 635.122396] ext4_ext_map_blocks:eh count1
[ 635.123571] ext4_ext_map_blocks:eh count0
[ 635.124555] ext4_ext_map_blocks:eh count0
[ 635.125276] ext4_ext_map_blocks: len 1 allocated 1
[ 635.126241] ext4_mb_use_inode_pa: free 4 will use 1
[ 635.127078] assign g_nh ffff8881004c80d0
[ 635.127964] ext4_ext_map_blocks:eh count1
[ 635.128626] Found path 3 3
[ 635.156284] fault inject
[ 635.156902] Buffer I/O error on dev sda, logical block 46, lost async page write
[ 635.158484] inject simulate inode IO error
[ 636.438787] jbd2_log_do_checkpoint: wait ck
[ 637.425052] EXT4-fs error (device sda): ext4_check_bdev_write_error:217: comm bb: Error while async write back metadata
[ 637.428726] ext4_ext_map_blocks:eh count0
[ 637.429442] look es lblk 1 len 4294967294 hole 1 delay 0 unwrite 0 write 0
[ 637.430568] look es lblk 2 len 4294967293 hole 1 delay 0 unwrite 0 write 0
[ 637.431679] look es lblk 3 len 4294967292 hole 1 delay 0 unwrite 0 write 0
[ 637.432823] ext4_ext_map_blocks:eh count0
[ 637.434308] ext4_ext_map_blocks: len 4 allocated 4
[ 637.435857] ext4_mb_use_inode_pa: free 3 will use 4
[ 637.437452] ------------[ cut here ]------------
[ 637.438115] kernel BUG at fs/ext4/mballoc.c:3840!
[ 637.438845] invalid opcode: 0000 [#1] SMP
[ 637.439423] CPU: 3 PID: 887 Comm: kworker/u8:0 Not tainted 5.10.0-00391-g1de2191913d0-dirty #183
[ 637.440656] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS ?-20190727_073836-buildvm-ppc64le-16.ppc.fedoraproject.org-3.fc31 04/01/2014
[ 637.442490] Workqueue: writeback wb_workfn (flush-8:0)
[ 637.443220] RIP: 0010:ext4_mb_use_inode_pa+0x155/0x200
[ 637.443961] Code: 48 83 05 2d ff 4a 0c 01 0f 0b 48 83 05 2b ff 4a 0c 01 48 83 05 2b ff 4a 0c 01 48 83 05 2b ff 4a 0c 01 48 83 05 2b ff 4a 0c 01 <0f9
[ 637.446548] RSP: 0018:ffffc9000077b828 EFLAGS: 00010202
[ 637.447274] RAX: 0000000000000003 RBX: 0000000000000004 RCX: 0000000000000000
[ 637.448272] RDX: 0000000000000736 RSI: ffff88842fd9c580 RDI: ffff88842fd9c580
[ 637.449268] RBP: 000000000000073a R08: 0000000000000000 R09: ffffc9000077b648
[ 637.450251] R10: 0000000000000001 R11: 0000000000000001 R12: ffff88810d07f000
[ 637.451232] R13: ffff8881004c82d8 R14: 0000000000000736 R15: ffff88810b566000
[ 637.452232] FS: 0000000000000000(0000) GS:ffff88842fd80000(0000) knlGS:0000000000000000
[ 637.453329] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 637.454120] CR2: 00007ffe67c622cf CR3: 0000000104c08000 CR4: 00000000000006e0
[ 637.455088] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[ 637.456050] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
[ 637.457024] Call Trace:
[ 637.457388] ? show_regs.cold+0x22/0x2f
[ 637.457924] ? __die_body+0x23/0x90
[ 637.458408] ? __die+0x34/0x41
[ 637.458831] ? die+0x3b/0x80
[ 637.459239] ? do_trap+0x117/0x150
[ 637.459715] ? do_error_trap+0x85/0xd0
[ 637.460241] ? ext4_mb_use_inode_pa+0x155/0x200
[ 637.460867] ? exc_invalid_op+0x76/0xb0
[ 637.461396] ? ext4_mb_use_inode_pa+0x155/0x200
[ 637.462012] ? asm_exc_invalid_op+0x12/0x20
[ 637.462601] ? ext4_mb_use_inode_pa+0x155/0x200
[ 637.463210] ? ext4_mb_use_inode_pa+0xb1/0x200
[ 637.463813] ext4_mb_use_preallocated+0x391/0x3e0
[ 637.464458] ext4_mb_new_blocks+0x2d3/0x2350
[ 637.465036] ? vprintk_default+0x21/0x30
[ 637.465567] ? vprintk_func+0x79/0x180
[ 637.466079] ? ext4_find_extent+0x639/0x890
[ 637.466659] ? printk+0x4f/0x58
[ 637.467089] ext4_ext_map_blocks+0xa04/0x1837
[ 637.467692] ? stack_trace_save+0x43/0x60
[ 637.468244] ext4_map_blocks+0x13b/0x9b0
[ 637.468785] ? kmem_cache_alloc+0x40e/0x920
[ 637.469368] ext4_writepages+0x86e/0x14d0
[ 637.469921] ? find_next_and_bit+0x10/0x20
[ 637.470499] ? cpumask_next_and+0x22/0x30
[ 637.471042] ? find_busiest_group+0x5d9/0x10f0
[ 637.471649] ? do_writepages+0x31/0xb0
[ 637.472163] ? enqueue_entity+0x562/0x1480
[ 637.472723] do_writepages+0x31/0xb0
[ 637.473222] __writeback_single_inode+0x48/0x520
[ 637.473850] writeback_sb_inodes+0x231/0x700
[ 637.474436] __writeback_inodes_wb+0x88/0x120
[ 637.475028] wb_writeback+0x2cd/0x4a0
[ 637.475533] ? find_next_bit+0x18/0x30
[ 637.476046] wb_workfn+0x252/0x730
[ 637.476515] ? x2apic_send_IPI+0x38/0x50
[ 637.477045] ? native_send_call_func_single_ipi+0x1c/0x30
[ 637.477784] ? ttwu_queue_wakelist+0xd6/0x110
[ 637.478386] process_one_work+0x27a/0x5f0
[ 637.478934] worker_thread+0x28b/0x6b0
[ 637.479454] ? rescuer_thread+0x570/0x570
[ 637.480000] kthread+0x153/0x1b0
[ 637.480448] ? kthread_flush_work+0x150/0x150
[ 637.481048] ret_from_fork+0x1f/0x30
[ 637.481544] Modules linked in:
[ 637.482010] ---[ end trace 8407349aa246522f ]---
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
合入修复补丁后,运行复现用例,内核不在BUGON
[ 35.711161] ext4_ext_map_blocks:eh count3
[ 37.135073] jbd2_log_do_checkpoint: wait ck
[ 39.930025] ext4_ext_map_blocks:eh count0
[ 39.931301] look es lblk 1 len 4294967294 hole 1 delay 0 unwrite 0 write 0
[ 39.933159] look es lblk 2 len 4294967293 hole 1 delay 0 unwrite 0 write 0
[ 39.934306] look es lblk 3 len 4294967292 hole 1 delay 0 unwrite 0 write 0
[ 39.935629] ext4_ext_map_blocks:eh count0
[ 39.936837] ext4_ext_map_blocks: len 4 allocated 4
[ 39.938158] EXT4-fs (sda): invalid pa, pa_free(3) < len(4)
[ 39.939621] EXT4-fs error (device sda): ext4_mb_use_preallocated:3994: comm kworker/u8:2: drop pa and mark group 0 block bitmap corrupted
[ 39.942253] EXT4-fs (sda): Delayed block allocation failed for inode 12 at logical offset 0 with max blocks 4 with error 28
[ 39.943770] EXT4-fs (sda): This should not happen!! Data will be lost
[ 39.944828] EXT4-fs (sda): Total free blocks count 0
[ 39.945510] EXT4-fs (sda): Free/Dirty block details
[ 39.946154] EXT4-fs (sda): free_blocks=3
[ 39.946736] EXT4-fs (sda): dirty_blocks=4
[ 39.947474] EXT4-fs (sda): Block reservation details
[ 39.948457] EXT4-fs (sda): i_reserved_data_blocks=4
登录 后才可以发表评论