[arch-commits] Commit in mlocate/trunk (PKGBUILD updatedb.service updatedb.timer)

Evangelos Foutras foutrelis at archlinux.org
Wed Apr 21 13:21:26 UTC 2021


    Date: Wednesday, April 21, 2021 @ 13:21:25
  Author: foutrelis
Revision: 412981

upgpkg: mlocate 0.26.git.20170220-7: add randomized delay to updatedb.timer

Requested in FS#68548 and recently added to plocate upstream as well.

While we're at it, also add some basic hardening to updatedb.service,
and tweak its CPU priority and I/O scheduling class to ease strain on
the system.

Modified:
  mlocate/trunk/PKGBUILD
  mlocate/trunk/updatedb.service
  mlocate/trunk/updatedb.timer

------------------+
 PKGBUILD         |    6 +++---
 updatedb.service |    7 +++++++
 updatedb.timer   |    2 +-
 3 files changed, 11 insertions(+), 4 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-04-21 13:15:31 UTC (rev 412980)
+++ PKGBUILD	2021-04-21 13:21:25 UTC (rev 412981)
@@ -5,7 +5,7 @@
 pkgname=mlocate
 pkgver=0.26.git.20170220
 _commit=c98bf6595703456558a6f9c163c746cdaa9e591f
-pkgrel=6
+pkgrel=7
 pkgdesc='Merging locate/updatedb implementation'
 url='https://pagure.io/mlocate'
 arch=('x86_64')
@@ -24,8 +24,8 @@
             'SKIP'
             '1713a8fc8b81f4a390bf8597c4c0e917474379002dcc984aad2f44218d10c82a'
             'd00796741e2194032d0185b40de70ff5c8a11fda416a70434eb0aa2020981f91'
-            '2e813effb651fae101d93722827553c6b9b9d42e898e808db4991eafdd330e02'
-            '83c7a508bad5dccd55a158cf8b8029d680f82cf8b1d21074279def14d9ad4dee')
+            '94520117a4a2e16b5f2311c406904369d72690b8998c39ee4cf758009fdddbcb'
+            'af0db83e34ffd0325101042760d4a5e3bccacbc3a0ef42c997e42507bf4ba6a3')
 
 prepare() {
 	cd "${srcdir}/${pkgname}"

Modified: updatedb.service
===================================================================
--- updatedb.service	2021-04-21 13:15:31 UTC (rev 412980)
+++ updatedb.service	2021-04-21 13:21:25 UTC (rev 412981)
@@ -4,4 +4,11 @@
 [Service]
 Type=oneshot
 ExecStart=/usr/bin/updatedb
+Nice=19
 IOSchedulingClass=idle
+IOSchedulingPriority=7
+
+PrivateTmp=true
+PrivateDevices=true
+PrivateNetwork=true
+ProtectSystem=full

Modified: updatedb.timer
===================================================================
--- updatedb.timer	2021-04-21 13:15:31 UTC (rev 412980)
+++ updatedb.timer	2021-04-21 13:21:25 UTC (rev 412981)
@@ -3,5 +3,5 @@
 
 [Timer]
 OnCalendar=daily
-AccuracySec=12h
+RandomizedDelaySec=12h
 Persistent=true



More information about the arch-commits mailing list