Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934138AbcKJP2b (ORCPT ); Thu, 10 Nov 2016 10:28:31 -0500 Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:41541 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933482AbcKJP22 (ORCPT ); Thu, 10 Nov 2016 10:28:28 -0500 Subject: Re: btrfs btree_ctree_super fault To: Dave Jones , Linus Torvalds , Jens Axboe , Andy Lutomirski , Andy Lutomirski , Al Viro , Josef Bacik , David Sterba , linux-btrfs , Linux Kernel , Dave Chinner References: <203e0319-bc9b-245c-e162-709267540d22@fb.com> <20161026233808.GC15247@clm-mbp.thefacebook.com> <20161026234751.e66xyzjiwifvbuha@codemonkey.org.uk> <20161031185514.b22zvbxvga4xcinz@codemonkey.org.uk> <20161031194454.GA49877@clm-mbp.thefacebook.com> <20161106165539.ybwm6rqvzh2k6uja@codemonkey.org.uk> <20161108145912.fcjvwxcpqgd7kjei@codemonkey.org.uk> <01d76d90-8d90-e09b-40a0-63488425348d@fb.com> <20161110143520.6fdu34afv45ui3y6@codemonkey.org.uk> From: Chris Mason Message-ID: <9723b056-f484-a6f6-0b6f-fd10f7b772f6@fb.com> Date: Thu, 10 Nov 2016 10:27:56 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: <20161110143520.6fdu34afv45ui3y6@codemonkey.org.uk> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [2620:10d:c091:180::1:a39c] X-ClientProxiedBy: BN6PR14CA0005.namprd14.prod.outlook.com (10.173.157.143) To CY4PR15MB1239.namprd15.prod.outlook.com (10.172.178.138) X-Microsoft-Exchange-Diagnostics: 1;CY4PR15MB1239;2:G3qwRwp9BinYxkTuP/s8ma+K2/R4bcYbQQFT8BU8hAkDIXoTE827Cttk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ECyKMRRT2GVApJtnxPUkore4QBp5tDujs9rG8xT48FoYdypNpGm9M5sWHd1VGe5Jk4xXpvO0oAZm7vgbKIlxXeujnjezw2AS5JfLdHcrRa5fE210zw==;20:0YNbh2jTWR8OxqkjxUtsRCkvJNOF4bQW2Lj0aAuZCwYMyv0majV3mbqL3g5hZQp63RAv8t7ILyWNeCLv80y0q4tylRJkPcYxZmDR6nTGbkBSG9Ycg6pJwv+DcKO1uSLYjuJP+K++LYrJDI4HV3hTe6okJgHfrzdB/ysVBXvwGGM=;4:1dAOQcftnP0t0PS4ZWv2GkkHgEg5OUiBVvLpphctrTigHmvEgbtgj7UwRF7gxewlmiwX8ww63mVdWmaIWhfUXoj12maFYtySMfZvZOe+CRGmUkUwqY2eOnReu4gW/u23DBXgCVVkTz785knq5kNlr7X22BJKWkiEh9QCPfBNEpptPnj+2oM8fuCv3025W75zrPdyUY+Kt+C4DOy47me3rgY7wQnu6Fdw5dLRIIR/qbNmQDS6i11IIGWMRvZ2iZvnYMBdh6aTnZ5tjrLfGj+HcQIUjSQCwy2JhUlW09m6kFeJGte5vwt0hF2yx3sYDqVIjr2L2OYtNdW2IRWHQGsGhjc1kXujidJK9ot7hLCofzQ1x7jiyQ/A2Uha4s+ofO/5syNIn6maI2gpNeEhrRfJAQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046);SRVR:CY4PR15MB1239;BCL:0;PCL:0;RULEID:;SRVR:CY4PR15MB1239; X-Forefront-PRVS: 01221E3973 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(4630300001)(6009001)(7916002)(377454003)(199003)(189002)(24454002)(5890100001)(4001350100001)(68736007)(107886002)(50466002)(189998001)(97736004)(101416001)(65826007)(42186005)(93886004)(7116003)(5660300001)(575784001)(86362001)(65956001)(31696002)(65806001)(47776003)(2950100002)(230700001)(551934003)(36756003)(64126003)(33646002)(7736002)(77096005)(305945005)(7846002)(2906002)(6666003)(5001770100001)(106356001)(6116002)(83506001)(105586002)(1706002)(31686004)(92566002)(586003)(81156014)(81166006)(76176999)(23746002)(50986999)(8676002)(229853002)(54356999)(921003)(1121003)(42262002);DIR:OUT;SFP:1102;SCL:1;SRVR:CY4PR15MB1239;H:[IPv6:2620:10d:c0a1:1110:8000::202a];FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?Windows-1252?Q?1;CY4PR15MB1239;23:Wm54HehItlH0T3NKcimnCSFNpLTb6OGqXjbCG?= =?Windows-1252?Q?sSiTvF+mbOlwyjwvG3b4vSsCeoPwCrX3djnlLbCXXwlJfX58r8L+pnNR?= =?Windows-1252?Q?eKbwginFgvXl1Oh+eDF+XIg+8hleALQQXhuHl1ZQBv2UWif5Y8ovLVto?= =?Windows-1252?Q?zjjSFEZ/1pXVfr23k6fbQ5/Zj4cH1VAqALgYOuDTXwoaS1HAll2DFQ41?= =?Windows-1252?Q?pkgOdWUos1v28uS2b/VUnQbGoTqkk0o2vovPqTSSNcLCx97d/+qxi8TP?= =?Windows-1252?Q?FjeTJix/6xVKXn13Mftwxo6tMdcd0IZwv3JtYqhhmA2fEU9L0oVHQ6lX?= =?Windows-1252?Q?Zz1uLK6nyYushZ8UEj+gY+7PkG03/8z0SkYdaA2a0Z/+g/n2tHjmN6Pb?= =?Windows-1252?Q?FF7nz3HuqdCZPgMqw19dF3JWu+YIymq5wer8dJ9eOXHWxDUNZtqUn4Sj?= =?Windows-1252?Q?dRBelZV4THnU+yb+HVkbJAKWtv9aSU7xqVUGnK2MOA/PxkBfnY9Nt5um?= =?Windows-1252?Q?+CYQpjFqd9LfWdDP9ZOyTMULG9Y7pK9yisV161uBwX/n9lvxIaKybvcs?= =?Windows-1252?Q?UPvm5/gKj/FbxQ+FFkK4iTUEpcew+jQka2fBHR/y9YpXQorwcHrfGSf8?= =?Windows-1252?Q?nDShDeY/FoD9yGIcjKEefLU5B8w1vAJODvmxV5haiYWfo6qEZ4YZunm1?= =?Windows-1252?Q?uJa1IeRhY7zCfO6jLchfpNZc/zbPsdrrCHM5XJgTeB9ORCi5FbGbS7hU?= =?Windows-1252?Q?U5AoaFUGFSJpteXFxQQeUBaV3R3F89tSkcoTKSF2nvPePF+atT8rJQ5u?= =?Windows-1252?Q?d7Xjk4+j+hQHQK61tJNHOpenA73TYCfUy/+zYgQWDigSvEKd7Jcrt43n?= =?Windows-1252?Q?QAf5KQkRdbArwFmNLTt9sX+fOUq0C9PTzDfnTa2egLBovn1FMFF4fLrt?= =?Windows-1252?Q?2sMjxWJj3Vs6UxxI7u2ftbrhCYw2jGwRVuCjbnbXwgdStMoVYBNfOK23?= =?Windows-1252?Q?HP0Umeu4PW0eqRKZO0BLvMEGCBpEEJfzi5HPQ2Tj8HafTnxfFDgsNx+/?= =?Windows-1252?Q?7NqUdZC7evAFXUuRIZcdmqFRbi0bB30/vpf/dla7XVJIlX787HM5i9I6?= =?Windows-1252?Q?rd3l6GEpFU2LmvDusFuZYQVyY/WGo8vIHn0de3h4QvsZFlZ+mJKh5V4R?= =?Windows-1252?Q?nl0QvOlaWaWpYJl1VW+Rz6PP95S2oyqrMLSwxu/rBa9ZhnYC18pl/NHW?= =?Windows-1252?Q?63F5OmJaXXlKdkwNNgoxxW6m9DzftE5hokUW/O6y5Z64oRmhefZZ44Xd?= =?Windows-1252?Q?nHDkrsuMyPzasNkQGJliajovYBSpXCp08r2osMswGxdRjivifPjRe79t?= =?Windows-1252?Q?d2KCEF5gOKZ/r+iBtRXt+z6z+Cukrhvbq1vZRU0flxB/5xgQwoVjlKat?= =?Windows-1252?Q?8hFpWjCgOcqc4QiNmYJbm3U4FrifzjyLkAXOSpNm0BpPG4MhFbNNq0BL?= =?Windows-1252?Q?EgJyoOwcud+vRPK1JiA1A06o4VeZGgrEqOW94pKThk/sZwqNg=3D=3D?= X-Microsoft-Exchange-Di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uLn78UDaRTdWo2gLyoCTCKq+V/rvkIxHgqW+yDHV62pJ42j9hQlh1id6KU4+Q/mKz3DphnW8ab+cI/+rT4hlXxJ1bFtH61Wh8axvEU/bxutb+hldfIv4+DttctZIVNWa0wF5pmammn3SGVP70o9Y= X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Nov 2016 15:28:07.8895 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR15MB1239 X-OriginatorOrg: fb.com X-Proofpoint-Spam-Reason: safe X-FB-Internal: Safe X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-11-10_07:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3907 Lines: 79 On 11/10/2016 09:35 AM, Dave Jones wrote: > On Tue, Nov 08, 2016 at 10:08:04AM -0500, Chris Mason wrote: > > > > And another new one: > > > > > > kernel BUG at fs/btrfs/ctree.c:3172! > > > > > > Call Trace: > > > [] __btrfs_drop_extents+0xb00/0xe30 [btrfs] > > > > We've been hunting this one for at least two years. It's the white > > whale of btrfs bugs. Josef has a semi-reliable reproducer now, but I > > think it's not the same as the pagevec based problems you reported earlier. > > Great, now for whatever reason, I'm hitting this over and over. > > Even better, after the last time I hit it, it reboot and this happened during boot.. > > BTRFS info (device sda6): disk space caching is enabled > BTRFS info (device sda6): has skinny extents > BTRFS info (device sda3): disk space caching is enabled > ------------[ cut here ]------------ > WARNING: CPU: 1 PID: 443 at fs/btrfs/file.c:546 btrfs_drop_extent_cache+0x411/0x420 [btrfs] > CPU: 1 PID: 443 Comm: mount Not tainted 4.9.0-rc4-think+ #1 > ffffc90000c4b468 ffffffff813b66bc 0000000000000000 0000000000000000 > ffffc90000c4b4a8 ffffffff81086d2b 0000022200c4b488 000000000002f265 > 40c8dded1afd6000 ffff8804ff5cddc8 ffff8804ef26f2b8 40c8dded1afd5000 > Call Trace: > [] dump_stack+0x4f/0x73 > [] __warn+0xcb/0xf0 > [] warn_slowpath_null+0x1d/0x20 > [] btrfs_drop_extent_cache+0x411/0x420 [btrfs] > [] ? alloc_debug_processing+0x73/0x1b0 > [] __btrfs_drop_extents+0x44f/0xe30 [btrfs] > [] ? btrfs_alloc_path+0x1a/0x20 [btrfs] > [] ? btrfs_alloc_path+0x1a/0x20 [btrfs] > [] ? kmem_cache_alloc+0x2aa/0x330 > [] ? btrfs_alloc_path+0x1a/0x20 [btrfs] > [] btrfs_drop_extents+0x79/0xa0 [btrfs] > [] replay_one_extent+0x1e1/0x710 [btrfs] > [] replay_one_buffer+0x26d/0x7e0 [btrfs] > [] ? ___slab_alloc.constprop.83+0x27c/0x5c0 > [] ? btrfs_alloc_path+0x1a/0x20 [btrfs] > [] ? debug_smp_processor_id+0x17/0x20 > [] walk_up_log_tree+0xeb/0x240 [btrfs] > [] walk_log_tree+0xa6/0x1d0 [btrfs] > [] btrfs_recover_log_trees+0x1dc/0x460 [btrfs] > [] ? replay_one_extent+0x710/0x710 [btrfs] > [] open_ctree+0x2575/0x2670 [btrfs] > [] btrfs_mount+0xd0b/0xe10 [btrfs] > [] ? pcpu_alloc+0x2d4/0x660 > [] ? lockdep_init_map+0x61/0x200 > [] ? __init_waitqueue_head+0x3b/0x50 > [] mount_fs+0x14/0xa0 > [] vfs_kern_mount+0x6b/0x150 > [] btrfs_mount+0x2c8/0xe10 [btrfs] > [] ? pcpu_alloc+0x2d4/0x660 > [] ? lockdep_init_map+0x61/0x200 > [] ? lockdep_init_map+0x61/0x200 > [] ? __init_waitqueue_head+0x3b/0x50 > [] mount_fs+0x14/0xa0 > [] vfs_kern_mount+0x6b/0x150 > [] do_mount+0x1c2/0xda0 > [] ? memdup_user+0x60/0x90 > [] SyS_mount+0x83/0xd0 > [] do_syscall_64+0x61/0x170 > [] entry_SYSCALL64_slow_path+0x25/0x25 > ---[ end trace d3fa03bb9c115bbe ]--- > BTRFS: error (device sda3) in btrfs_replay_log:2491: errno=-17 Object already exists (Failed to recover log tree) > BTRFS error (device sda3): cleaner transaction attach returned -30 > BTRFS error (device sda3): open_ctree failed > > > Guess I'll hit it with btrfsck and hope for the best.. You can zero the log if you need to. Josef has a ton of tracing around this right now, so I'm hoping we nail it down very soon. -chris