Linux XFS filesystem development
 help / color / mirror / Atom feed
From: Patrick Fischer <patrick.fischer@siedl.net>
To: linux-xfs@vger.kernel.org
Subject: xfs_scrub_all process execution results in a dead lock condition
Date: Thu, 30 Apr 2026 15:00:01 +0200 (CEST)	[thread overview]
Message-ID: <323580211.1220195.1777554001363.JavaMail.zimbra@siedl.net> (raw)

Hello,
I've encountered a bug within the xfsprogs-dev utilities, particular within the Python script xfs_scrub_all.
I researched the master branch and saw, that the type of sub process call is like within kernel version 6.13.0-2 I stumbled across this issue.

Overview:
xfs_scrub_all.service systemd unit (or manual execution) is hanging due to a pipe buffer exhaustion after sub process call of lsblk.

Steps to reproduce:
Create a bunch of fake block devices to enlarge the output of lsblk to more than 65520 bytes:
> modprobe scsi_debug max_lunx=3 num_tgts=7 add_hosts=100


Run the command of xfs_scrub_all.service manually:
> /usr/sbin/xfs_scrub_all --auto-media-scan-interval 1mo


xfs_scrub_all shows a wait4 for the sub process lsblk:
> wait4(2148527,


Within sub process lsblk there is a write to FD1 / stdout:
> write(1, "                     {\n         "..., 4096


Affected Code in /usr/sbin/xfs_scrub_all[1]:
> 54     cmd=['lsblk', '-o', 'NAME,KNAME,TYPE,FSTYPE,MOUNTPOINT', '-J']
> 55     result = subprocess.Popen(cmd, stdout=subprocess.PIPE)
> 56     result.wait()
> 57     if result.returncode != 0:
> 58         return fs


Actual Results:
The execution of the command above launches a sub process of lsblk and returns more than 65520 bytes, resulting in an endless wait for return.

Expected Results:
The unit / process should not enter a dead lock.

[1] https://git.kernel.org/pub/scm/fs/xfs/xfsprogs-dev.git/tree/scrub/xfs_scrub_all.py.in

Regards,
Patrick Fischer

Die E-Mail wurde von IKARUS mail.security geprüft.

             reply	other threads:[~2026-04-30 13:03 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-30 13:00 Patrick Fischer [this message]
2026-04-30 15:50 ` xfs_scrub_all process execution results in a dead lock condition Darrick J. Wong

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=323580211.1220195.1777554001363.JavaMail.zimbra@siedl.net \
    --to=patrick.fischer@siedl.net \
    --cc=linux-xfs@vger.kernel.org \
    /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