[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
06/06: services: syslogd: Do not fsync at each line.
From: |
guix-commits |
Subject: |
06/06: services: syslogd: Do not fsync at each line. |
Date: |
Mon, 6 Jun 2022 16:45:04 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guix.
commit 264ca9452fae827d6621b28b8972f4b1d68401a1
Author: Ludovic Courtès <ludo@gnu.org>
AuthorDate: Mon Jun 6 22:35:12 2022 +0200
services: syslogd: Do not fsync at each line.
Fixes <https://issues.guix.gnu.org/55707>.
Previously Inetutils' syslogd would call 'fsync' after each line written
to a file. This would significantly increase boot times on machines
with slow-ish spinning HDDs, where each 'fsync' call would take between
0.1s and 0.4s (and we'd do two of them for each line, one for
/var/log/messages and one for /var/log/debug).
* gnu/services/base.scm (%default-syslog.conf): Add a '-' before each
file name, except /var/log/secure. Change what goes to /var/log/debug.
---
gnu/services/base.scm | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/gnu/services/base.scm b/gnu/services/base.scm
index f27365bbe6..6865d03f25 100644
--- a/gnu/services/base.scm
+++ b/gnu/services/base.scm
@@ -1397,23 +1397,24 @@ responsible for logging system messages.")))
# level notice or higher and anything of level err or
# higher to the console.
# Don't log private authentication messages!
- *.alert;auth.notice;authpriv.none /dev/console
+ *.alert;auth.notice;authpriv.none -/dev/console
# Log anything (except mail) of level info or higher.
# Don't log private authentication messages!
- *.info;mail.none;authpriv.none /var/log/messages
+ *.info;mail.none;authpriv.none -/var/log/messages
- # Like /var/log/messages, but also including \"debug\"-level logs.
- *.debug;mail.none;authpriv.none /var/log/debug
+ # Log \"debug\"-level entries and nothing else.
+ *.=debug -/var/log/debug
# Same, in a different place.
- *.info;mail.none;authpriv.none /dev/tty12
+ *.info;mail.none;authpriv.none -/dev/tty12
# The authpriv file has restricted access.
+ # 'fsync' the file after each line (hence the lack of a leading dash).
authpriv.* /var/log/secure
# Log all the mail messages in one place.
- mail.* /var/log/maillog
+ mail.* -/var/log/maillog
"))
(define* (syslog-service #:optional (config (syslog-configuration)))
- branch master updated (e614cf2907 -> 264ca9452f), guix-commits, 2022/06/06
- 06/06: services: syslogd: Do not fsync at each line.,
guix-commits <=
- 05/06: packages: Use SRFI-71 instead of SRFI-11., guix-commits, 2022/06/06
- 02/06: gnu: Add python-canopen., guix-commits, 2022/06/06
- 01/06: bootloader: grub: Add removable grub-efi bootloader option., guix-commits, 2022/06/06
- 04/06: packages: Add 'specifications->packages'., guix-commits, 2022/06/06
- 03/06: gnu: Add python-progress., guix-commits, 2022/06/06