On Thu, Apr 17, 2025 at 10:35:58AM +0100, David White wrote: > Hi there, > > I'm on Ubuntu 24.10 which has a secondary mount xfs filesystem. > > I have installed xfsprogs. Which installs a /usr/sbin/xfs_scrub_all > python script, and a systemd service and timer to run it. xfsprogs > version 6.8.0 (same on 6.9.0 built from source too) > > However, looking at the code for xfs_scrub_all, it's broken. It fails > on a non-existent "debug" global, and the run_scrub thread target has > a call to path_to_serviceunit with a "path" parameter that doesn't > exist. (I'm assuming this is supposed to be "mnt") Yes, and both bugs were fixed in 6.10. > I've disabled this service, (and the timer that runs it) and added it > to my system presets for future installs not to enable this unit. > > What is going on here? What is the purpose? xfs_scrub_all schedules xfs_scrub@ services to run background online fsck of mounted XFS filesystems. That said, xfs_scrub_all before xfsprogs 6.10 has some of serious bugs in it (as you note!). Back in the 6.8 days days the kernel portion was not yet complete, and the userspace part didn't fully catch up until late last year. The strange part is that none of that stuff should be active in the xfsprogs 6.8 package for Debian or Ubuntu, unless I seriously misunderstand what this line in debian/rules does: dh_installsystemd -p xfsprogs --no-enable --no-start --no-restart-after-upgrade --no-stop-on-upgrade which (AFAIK) installs the units but does not enable or start any of them. But I'm guessing it got activated on your system anyway? From the postinst script of the package in question: https://mirrors.edge.kernel.org/ubuntu/pool/main/x/xfsprogs/xfsprogs_6.8.0-2.2ubuntu1_amd64.deb # Automatically added by dh_installsystemd/13.18ubuntu1 if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then if deb-systemd-helper debian-installed 'xfs_scrub_all.timer'; then # The following line should be removed in trixie or trixie+1 deb-systemd-helper unmask 'xfs_scrub_all.timer' >/dev/null || true if deb-systemd-helper --quiet was-enabled 'xfs_scrub_all.timer'; then # Create new symlinks, if any. deb-systemd-helper enable 'xfs_scrub_all.timer' >/dev/null || true fi fi # Update the statefile to add new symlinks (if any), which need to be cleaned # up on purge. Also remove old symlinks. deb-systemd-helper update-state 'xfs_scrub_all.timer' >/dev/null || true fi