From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD1FDC3A5A3 for ; Tue, 27 Aug 2019 22:10:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9883C2077B for ; Tue, 27 Aug 2019 22:10:55 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=colorremedies-com.20150623.gappssmtp.com header.i=@colorremedies-com.20150623.gappssmtp.com header.b="2NB4s637" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725976AbfH0WKy (ORCPT ); Tue, 27 Aug 2019 18:10:54 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:33169 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725804AbfH0WKy (ORCPT ); Tue, 27 Aug 2019 18:10:54 -0400 Received: by mail-wr1-f67.google.com with SMTP id u16so385813wrr.0 for ; Tue, 27 Aug 2019 15:10:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=colorremedies-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=qc839KheCGl7U3e1YOMWcC4Kru0c5b/pxJkcQ1H2imc=; b=2NB4s6376VnIOAEzznn2634qHDpJK1WA2Lw3QxFWM8+MlfbecTTh/KJJFSycEwZUnu dPDSoHpeprcpRhUmzAL+VJ112LjCix1ENd/AUAt1MyBMWEFV50BQIWWAvTgrPmjakQ9a VzVP8LOtazCOfioE7q7VRfdj4nJEmh4Ww4rtGtQoY22wz8462E7H73K4Am+lu38zzAV5 5D/f9ZmXEtBHA4HyRZ6zVpyPrMsyvvxzHgdP6umk0IdN0uFMA9i2rzFDoauLMJKJec5h eyNl/1tGL4Ab7LZnlY3a3a0Rtvo2S6HTScFhT3LHnhPuCEOYefjqIKLLK2rNmsFFki/R bgNg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=qc839KheCGl7U3e1YOMWcC4Kru0c5b/pxJkcQ1H2imc=; b=fzZbwCUJHq+/9usbCoQlNYq1VufFKBbzYmTAwBVDpDb5eeCcn357ug5HbMZ7B3spY/ /llsUhAQMOeOB453RvmyBnqqLiNIWbwiOaLu8H0MCkSVzemtdqfQrsRhMVPvMbjvt2Pd Hvei5QYb96S9q5dYVJU00DXBYbDhJ6lHSJjhJGiU2h85eaw+1dc+1cyQ8s/9k9Qeh2/m a+mtOyfVC5y9YU2h4v04WJm0xI/PrurfCkWi3QWP8G3fJlvgW9S6vsahskGFMROkOQO4 owVq/DkiplyXhrseBdLL1HdfhcT/CZyZNtE5HwP30cnBBOEQtDGUWmGpNDD0wYOtv/ZP fbUg== X-Gm-Message-State: APjAAAUJK6SzArqPmO0X+WM8QvPy0KG6QqWtLPhQDSZWb5cgO2deVSam GeETR9e/aZzjkBzuP0cJPmsAw51lDXM/+yj6bVCJ8g== X-Google-Smtp-Source: APXvYqyyAa5vnMe/QttptuZTALXT/DRa6D73t5NncxuwL0QjP4ci3TDY+fuDFAfbfOvJHKlTofYDdKUqRPdD3mHW8sQ= X-Received: by 2002:a5d:494d:: with SMTP id r13mr374009wrs.82.1566943852762; Tue, 27 Aug 2019 15:10:52 -0700 (PDT) MIME-Version: 1.0 References: <11e4e889f903ddad682297c4420faeb0245414cf.camel@scientia.net> <18d24f2f-4d33-10aa-5052-c358d4f7c328@petaramesh.org> <5aefca34-224a-0a81-c930-4ccfcd144aef@petaramesh.org> <4bd70aa2-7ad0-d5c6-bc1f-22340afaac60@petaramesh.org> <370697f1-24c9-c8bd-01a7-c2885a7ece05@gmx.com> In-Reply-To: From: Chris Murphy Date: Tue, 27 Aug 2019 16:10:41 -0600 Message-ID: Subject: Re: Massive filesystem corruption since kernel 5.2 (ARCH) To: Alberto Bursi Cc: =?UTF-8?Q?Sw=C3=A2mi_Petaramesh?= , Qu Wenruo , "linux-btrfs@vger.kernel.org" , Christoph Anton Mitterer Content-Type: text/plain; charset="UTF-8" Sender: linux-btrfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org On Tue, Aug 27, 2019 at 5:11 AM Alberto Bursi wrote: > If you want to fully clear cache you need to use (on an unmounted > filesystem) > > btrfs check --clear-space-cache v1 /dev/sdX > > or > > btrfs check --clear-space-cache v2 /dev/sdX I recommend a minimum version of btrfs-progs 5.1 for either of these commands. Before that version, a crash mid write of updating the extent tree can cause file system corruption. In my case, all data could be extracted merely by mounting -o ro, but I did have to recreated that file system from scratch. -- Chris Murphy