public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <djwong@kernel.org>
To: Eric Sandeen <sandeen@redhat.com>
Cc: "linux-xfs@vger.kernel.org" <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH] xfs_repair: notify user when cache flush starts
Date: Fri, 10 Nov 2023 11:40:22 -0800	[thread overview]
Message-ID: <20231110194022.GM1205143@frogsfrogsfrogs> (raw)
In-Reply-To: <3ca21cbc-fbe2-4c43-b8af-50bc7467b9cd@redhat.com>

On Fri, Nov 10, 2023 at 12:22:30PM -0600, Eric Sandeen wrote:
> We recently had the opportunity to run xfs_repair on a system
> with 2T of memory and over a billion inodes. After phase 7
> had completed, xfs_repair appeared to have hung for over an
> hour as the massive cache was written back.
> 
> In the long run it might be nice to see if we can add progress
> reporting to the cache flush if it's sufficiently large, but
> for now at least let the user know what's going on.
> 
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> ---
> 
> diff --git a/repair/xfs_repair.c b/repair/xfs_repair.c
> index ff29bea9..5597b9ba 100644
> --- a/repair/xfs_repair.c
> +++ b/repair/xfs_repair.c
> @@ -1388,6 +1388,7 @@
>  	 * verifiers are run (where we discover the max metadata LSN), reformat
>  	 * the log if necessary and unmount.
>  	 */
> +	do_log(_("Flushing cache...\n"));

Does this new message affect the golden output of any fstests?

Also, while this /does/ flush the libxfs b(uffer)cache, I worry that
the phrasing will lead people into thinking that *disk* caches are being
flushed.  That doesn't happen until libxfs_close_devices.  I suggest:

"Writing dirty buffers..." ?

--D

>  	libxfs_bcache_flush();
>  	format_log_max_lsn(mp);
> 
> 

  reply	other threads:[~2023-11-10 19:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-10 18:22 [PATCH] xfs_repair: notify user when cache flush starts Eric Sandeen
2023-11-10 19:40 ` Darrick J. Wong [this message]
2023-11-13 16:33   ` Eric Sandeen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231110194022.GM1205143@frogsfrogsfrogs \
    --to=djwong@kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox