25f9c8
From ebb628f8b6e9564c036fce152f67512e5755dcfc Mon Sep 17 00:00:00 2001
25f9c8
From: Karel Zak <kzak@redhat.com>
25f9c8
Date: Mon, 6 Dec 2021 13:20:37 +0100
25f9c8
Subject: [PATCH 68/74] fstrim: improve timer setting
25f9c8
25f9c8
Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1916151
25f9c8
Signed-off-by: Karel Zak <kzak@redhat.com>
25f9c8
---
25f9c8
 sys-utils/fstrim.timer | 2 ++
25f9c8
 1 file changed, 2 insertions(+)
25f9c8
25f9c8
diff --git a/sys-utils/fstrim.timer b/sys-utils/fstrim.timer
25f9c8
index 3a3762d5c..54b3c18f5 100644
25f9c8
--- a/sys-utils/fstrim.timer
25f9c8
+++ b/sys-utils/fstrim.timer
25f9c8
@@ -1,11 +1,13 @@
25f9c8
 [Unit]
25f9c8
 Description=Discard unused blocks once a week
25f9c8
 Documentation=man:fstrim
25f9c8
+ConditionVirtualization=!container
25f9c8
 
25f9c8
 [Timer]
25f9c8
 OnCalendar=weekly
25f9c8
 AccuracySec=1h
25f9c8
 Persistent=true
25f9c8
+RandomizedDelaySec=6000
25f9c8
 
25f9c8
 [Install]
25f9c8
 WantedBy=timers.target
25f9c8
-- 
25f9c8
2.31.1
25f9c8