From patchwork Mon Aug 26 21:31:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Darrick J. Wong" X-Patchwork-Id: 11115711 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E3D7614DB for ; Mon, 26 Aug 2019 21:33:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C152921872 for ; Mon, 26 Aug 2019 21:33:11 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="Azgw02AJ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728708AbfHZVdL (ORCPT ); Mon, 26 Aug 2019 17:33:11 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:36988 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728532AbfHZVdL (ORCPT ); Mon, 26 Aug 2019 17:33:11 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x7QLDmlB000904; Mon, 26 Aug 2019 21:33:09 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : from : to : cc : date : message-id : mime-version : content-type : content-transfer-encoding; s=corp-2019-08-05; bh=xPMoN+ucKwebLiojth5UT154j/N56bXH0auyPyup7po=; b=Azgw02AJhbnqQGQvgvQnZxbFdw98NQb64lX711xTKzGrDQNzaWU1c3+r/t20FVXysMo4 u0QBPY2Jk9Xzn+VmnNgc9IySg4hkXEF3ryOBUPAUqFxYMGViAFR3lmiLhVKvsK2hfA54 Ss60PKu8+phXMDYTRX9Hb02h0Rxhq6jPngZ8/3Bcx5uKYouZI1PaZ3wsAX8c6tKKKP8U ZHZc2WpRKsxuyCoJSJ60AOE9xadYO77kKo7YMTVhFmSq81FmNZfm+TPeLyie5p0qYOlZ TX1CqjPqnE22KyOLuVYTlj17Z+lou6BOvqUNy9ERWhmnmco0EOnBlIgEwmk/JsYFAwpg 4A== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by aserp2120.oracle.com with ESMTP id 2umpxx05u8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 26 Aug 2019 21:33:09 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x7QLITlv025207; Mon, 26 Aug 2019 21:31:08 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userp3030.oracle.com with ESMTP id 2umj1tk8sy-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 26 Aug 2019 21:31:08 +0000 Received: from abhmp0009.oracle.com (abhmp0009.oracle.com [141.146.116.15]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x7QLV7cS007696; Mon, 26 Aug 2019 21:31:07 GMT Received: from localhost (/10.159.144.227) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 26 Aug 2019 14:31:07 -0700 Subject: [PATCH 00/11] xfs_scrub: fix IO error reporting From: "Darrick J. Wong" To: sandeen@sandeen.net, darrick.wong@oracle.com Cc: linux-xfs@vger.kernel.org Date: Mon, 26 Aug 2019 14:31:06 -0700 Message-ID: <156685506615.2843133.16536353613627426823.stgit@magnolia> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9361 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908260198 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9361 signatures=668684 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908260198 Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org Hi all, The scrub media error reporting could use some improvements -- first, scrub can calculate the exact offset of media errors in file mappings, so we should report more precise offsets. Second, we only need to scan the rmap once after assembling the io error bitmap to look for destroyed metadata (instead of once per error!). Third, we can filter out unwritten and attr/cow fork extents from what we report since sector remapping takes care of unwritten/cow extents and attr media errors should be detected by phase 3. Finally, we introduce a new category of errors that are unfixable by scrub, and assign to this class all the media errors since there's nothing XFS can do. If you're going to start using this mess, you probably ought to just pull from my git trees, which are linked below. This is an extraordinary way to destroy everything. Enjoy! Comments and questions are, as always, welcome. --D xfsprogs git tree: https://git.kernel.org/cgit/linux/kernel/git/djwong/xfsprogs-dev.git/log/?h=scrub-media-error-reporting fstests git tree: https://git.kernel.org/cgit/linux/kernel/git/djwong/xfstests-dev.git/log/?h=scrub-media-error-reporting