From 06eeb83d3e175509f73d72ab095987520c98a148 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sun, 31 May 2026 11:39:07 +0200 Subject: [PATCH] tmpfiles: exclude x11 lock files from time-based cleanup We need a removal rule for systems where /tmp is not on tmpfs, so that if they crash, stale sockets will be removed during boot. OTOH, at runtime, those lock files must never be removed. But since the 'r!' rule uses '!', it only applies during boot. With the rule inactive, the usual time-based cleanup for /tmp/ was also applied to those files, causing them to be removed after 10 days. Fixes #35182. --- tmpfiles.d/x11.conf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tmpfiles.d/x11.conf b/tmpfiles.d/x11.conf index b45c8eec250..e83229590a4 100644 --- a/tmpfiles.d/x11.conf +++ b/tmpfiles.d/x11.conf @@ -14,5 +14,6 @@ D /tmp/.ICE-unix 1777 root root 1h D /tmp/.XIM-unix 1777 root root 1h D /tmp/.font-unix 1777 root root 1h -# Unlink the X11 lock files +# Unlink the X11 lock files at boot, but exclude them from time-based cleanup later r! /tmp/.X[0-9]*-lock +x /tmp/.X[0-9]*-lock -- 2.47.3