From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Sanders Subject: Re: btrfs hang in flush-btrfs-5 Date: Mon, 11 Jul 2011 12:40:34 +0100 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" To: linux-btrfs@vger.kernel.org Return-path: List-ID: Jeremy Sanders wrote: > Hi - I'm trying btrfs with kernel 2.6.38.8-32.fc15.x86_64 (a Fedora > kernel). I'm just doing a tar-to-tar copy onto the file system with > compress- force=zlib. Here are some traces of the stuck processes. I've managed to reproduce the hang using the latest btrfs from the repository. I had to remove some of the tracing lines to get it to compile under 2.6.38.8 and an ioctl which wasn't defined. Here is is where it is stuck: [ 8390.923737] flush-btrfs-4 D ffff88005aeef480 0 2965 2 0x00000080 [ 8390.923907] ffff8800026cb720 0000000000000046 ffff8800026cb690 ffffffff00000001 [ 8390.924037] 0000000000013840 0000000000013840 0000000000013840 ffff88005931ae60 [ 8390.924037] 0000000000013840 ffff8800026cbfd8 0000000000013840 0000000000013840 [ 8390.924037] Call Trace: [ 8390.924037] [] ? sync_page+0x0/0x4d [ 8390.924037] [] io_schedule+0x47/0x62 [ 8390.924037] [] sync_page+0x49/0x4d [ 8390.924037] [] __wait_on_bit_lock+0x46/0x8f [ 8390.924037] [] __lock_page+0x66/0x6d [ 8390.924037] [] ? wake_bit_function+0x0/0x31 [ 8390.924037] [] ? should_resched+0xe/0x2e [ 8390.924037] [] lock_page+0x3d/0x41 [btrfs] [ 8390.924037] [] lock_delalloc_pages+0xb7/0x1a2 [btrfs] [ 8390.924037] [] find_lock_delalloc_range.clone.18+0xd9/0x1cb [btrfs] [ 8390.924037] [] ? __lookup_tag+0xb9/0x123 [ 8390.924037] [] __extent_writepage+0x156/0x561 [btrfs] [ 8390.924037] [] ? radix_tree_gang_lookup_tag_slot+0x81/0xa2 [ 8390.924037] [] ? find_get_pages_tag+0x6f/0xd5 [ 8390.924037] [] extent_write_cache_pages.clone.9.clone.16+0x134/0x2a1 [btrfs] [ 8390.924037] [] extent_writepages+0x47/0x5c [btrfs] [ 8390.924037] [] ? btrfs_get_extent+0x0/0x77f [btrfs] [ 8390.924037] [] ? bit_waitqueue+0x17/0xa9 [ 8390.924037] [] btrfs_writepages+0x27/0x29 [btrfs] [ 8390.924037] [] do_writepages+0x21/0x2a [ 8390.924037] [] writeback_single_inode+0x9c/0x19b [ 8390.924037] [] writeback_sb_inodes+0xa1/0x12b [ 8390.924037] [] writeback_inodes_wb+0x163/0x175 [ 8390.924037] [] wb_writeback+0x24f/0x368 [ 8390.924037] [] wb_do_writeback+0x183/0x19e [ 8390.924037] [] ? schedule_timeout+0xb3/0xe3 [ 8390.924037] [] bdi_writeback_thread+0x88/0x205 [ 8390.924037] [] ? bdi_writeback_thread+0x0/0x205 [ 8390.924037] [] kthread+0x82/0x8a [ 8390.924037] [] kernel_thread_helper+0x4/0x10 [ 8390.924037] [] ? kthread+0x0/0x8a [ 8390.924037] [] ? kernel_thread_helper+0x0/0x10 [ 8390.933163] tar D ffff880019053478 0 4195 2953 0x00000084 [ 8390.933163] ffff8800190533d8 0000000000000086 ffffffff813b9878 0000000000000010 [ 8390.933163] 0000000000013840 0000000000013840 0000000000013840 ffff880045beae60 [ 8390.933163] 0000000000013840 ffff880019053fd8 0000000000013840 0000000000013840 [ 8390.933163] Call Trace: [ 8390.933163] [] ? read_pmtmr+0x10/0x17 [ 8390.933163] [] ? sync_page+0x0/0x4d [ 8390.933163] [] io_schedule+0x47/0x62 [ 8390.933163] [] sync_page+0x49/0x4d [ 8390.933163] [] __wait_on_bit_lock+0x46/0x8f [ 8390.933163] [] __lock_page+0x66/0x6d [ 8390.933163] [] ? wake_bit_function+0x0/0x31 [ 8390.933163] [] lock_page+0x3d/0x41 [ 8390.933163] [] move_to_new_page+0x11e/0x195 [ 8390.933163] [] migrate_pages+0x24e/0x38d [ 8390.933163] [] ? compaction_alloc+0x0/0x29a [ 8390.933163] [] ? zone_page_state_add+0x2f/0x34 [ 8390.933163] [] compact_zone+0x3f0/0x5e1 [ 8390.933163] [] compact_zone_order+0xb0/0xbf [ 8390.933163] [] ? get_page_from_freelist+0x627/0x670 [ 8390.933163] [] try_to_compact_pages+0x91/0xe7 [ 8390.933163] [] __alloc_pages_direct_compact+0xa9/0x16f [ 8390.933163] [] __alloc_pages_nodemask+0x469/0x762 [ 8390.933163] [] ? signal_pending+0x17/0x21 [ 8390.933163] [] alloc_pages_current+0xb1/0xca [ 8390.933163] [] alloc_slab_page+0x1c/0x4a [ 8390.933163] [] new_slab+0x52/0x1a7 [ 8390.933163] [] __slab_alloc+0x224/0x302 [ 8390.933163] [] ? radix_tree_preload+0x34/0x85 [ 8390.933163] [] ? radix_tree_preload+0x34/0x85 [ 8390.933163] [] kmem_cache_alloc+0x5b/0xe1 [ 8390.933163] [] radix_tree_preload+0x34/0x85 [ 8390.933163] [] add_to_page_cache_locked+0x58/0x124 [ 8390.933163] [] add_to_page_cache_lru+0x2a/0x58 [ 8390.933163] [] find_or_create_page+0x5a/0x8a [ 8390.933163] [] prepare_pages.clone.9+0xf1/0x30a [btrfs] [ 8390.933163] [] ? block_rsv_add_bytes+0x24/0x4e [btrfs] [ 8390.933163] [] __btrfs_buffered_write.clone.11+0x126/0x2a1 [btrfs] [ 8390.933163] [] ? __mark_inode_dirty+0x30/0x169 [ 8390.933163] [] ? file_update_time+0xf7/0x111 [ 8390.933163] [] btrfs_file_aio_write+0x3da/0x492 [btrfs] [ 8390.933163] [] ? pipe_read+0x3bd/0x3d2 [ 8390.933163] [] ? __perf_event_task_sched_out+0x27/0x2c [ 8390.933163] [] do_sync_write+0xcb/0x108 [ 8390.933163] [] ? security_file_permission+0x2e/0x33 [ 8390.933163] [] vfs_write+0xac/0xff [ 8390.933163] [] sys_write+0x4a/0x6e [ 8390.933163] [] system_call_fastpath+0x16/0x1b Jeremy