From 7996e2b824358499643c9dc91948c34348db28d3 Mon Sep 17 00:00:00 2001 From: rugk Date: Thu, 15 Jul 2021 20:33:41 +0200 Subject: Randomize the auto-update of podman containers This makes sure, that the podman auto-update is not executed exactly at midnight for the same time always. If many things do the same and many services use this keyword and react at midnight, this can cause a lot of stress to a server. Thus, this adds a 900s/15min delay. As [the arch wiki says](https://wiki.archlinux.org/title/Systemd/Timers#Realtime_timer): > Special event expressions like daily and weekly refer to specific start times and thus any timers sharing such calendar events will start simultaneously. Timers sharing start events can cause poor system performance if the timers' services compete for system resources. The RandomizedDelaySec option in the [Timer] section avoids this problem by randomly staggering the start time of each timer. See systemd.timer(5). Signed-off-by: rugk --- contrib/systemd/auto-update/podman-auto-update.timer | 1 + 1 file changed, 1 insertion(+) diff --git a/contrib/systemd/auto-update/podman-auto-update.timer b/contrib/systemd/auto-update/podman-auto-update.timer index 3e50ffa9b..50be391d3 100644 --- a/contrib/systemd/auto-update/podman-auto-update.timer +++ b/contrib/systemd/auto-update/podman-auto-update.timer @@ -3,6 +3,7 @@ Description=Podman auto-update timer [Timer] OnCalendar=daily +RandomizedDelaySec=900 Persistent=true [Install] -- cgit v1.2.3-54-g00ecf