From patchwork Thu Feb 13 23:10:10 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 38577 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id CEA0627BBEA; Thu, 13 Feb 2025 23:11:36 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-8.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL, RCVD_IN_VALIDITY_SAFE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 139C227BBE2 for ; Thu, 13 Feb 2025 23:11:36 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tiiMN-0007Sc-Bg; Thu, 13 Feb 2025 18:11:07 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiMK-0007Rz-Hx for guix-patches@gnu.org; Thu, 13 Feb 2025 18:11:04 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tiiMJ-0001dU-Cq; Thu, 13 Feb 2025 18:11:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:In-Reply-To:References:Subject; bh=KJvH9NLF0e9GqOsze5c1FFpd0beiA+aSg+O7d749vt0=; b=kJIIwMtEqZmUPDhSgKideU0/xpnnuW3+IyfwZH7o9x3I4l6aQI32eCmUP/XoTHJUir1TRi+Qvvk2rblqUegpJ7wmgf+7sP7WemcAZZealUyw2FaPq3yUUFj4l8nvGYRpxRvNVjztVhu18SXwN7NohY/ImVMCUJkFDCklD7f/l7Z+UmeDwduuIllUK6mWQe9aNa5rYDrKSFJJi/y1JqChqJVZXGBXYOHRnf2M8ij/Otx7BKnVk9uzuMAuON43+5x2+98f4s23dRL1IW4uFc61Yvz0Fcsq4LV9N1Y0HNOlXpcx64ArCkWa/yxDNLRbTY40jCQE4ZBLsuorbjQIGbHg3A==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tiiMI-00029M-8K; Thu, 13 Feb 2025 18:11:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#76063] [PATCH v2 1/3] services: Add =?utf-8?b?4oCYc3lzdGVtLWxv?= =?utf-8?b?Z+KAmQ==?= Shepherd service. References: In-Reply-To: Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: ludo@gnu.org, maxim.cournoyer@gmail.com, guix-patches@gnu.org Resent-Date: Thu, 13 Feb 2025 23:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76063 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 76063@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer , Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer X-Debbugs-Original-Xcc: Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer Received: via spool by 76063-submit@debbugs.gnu.org id=B76063.17394882438226 (code B ref 76063); Thu, 13 Feb 2025 23:11:02 +0000 Received: (at 76063) by debbugs.gnu.org; 13 Feb 2025 23:10:43 +0000 Received: from localhost ([127.0.0.1]:46084 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tiiLy-00028W-BF for submit@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:43 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44668) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tiiLv-000287-Qo for 76063@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:40 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiLq-0001bH-4w; Thu, 13 Feb 2025 18:10:34 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=KJvH9NLF0e9GqOsze5c1FFpd0beiA+aSg+O7d749vt0=; b=hKt6M/9xeg27yH nu+Ku/rXGpsoqow1pcqYyX+SHgLzUrjTHImntlYnkgJpiAt356254rr89RT2JM3nbeB5SOMJlRxUX 91sDIjjsL1Ql7IA14b6S3oG+8xi7oS2Bzr+x1m4GeEO9DfgGl+TvOJIHIIySw1Gv/N2Iqh66hT965 zDi1Ou1TVkp2AzbA/UCGKFB830KajlCcXmXSDpzh+G4dqEPwKE5ldGj2PO1sI4eCiYXzdwvARYKTE TfZGrz8i5hipSdUbiTSiCCetOKEiKO5AuT2ZailrqIt8QhMMBWVTHdaeOnZABXvKwt5Nh837b+Ajx z1JkEcB/krdXC05L8/rg==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Fri, 14 Feb 2025 00:10:10 +0100 Message-ID: <55515c28a50da000da09f7cdb38f3efaf19f0236.1739488125.git.ludo@gnu.org> X-Mailer: git-send-email 2.48.1 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/services/shepherd.scm (gexp-or-integer?) (gexp-or-string?, gexp-or-string-or-false?): New procedures. (system-log-configuration): New record type. (shepherd-system-log-service-type): New variable. * doc/guix.texi (Shepherd Services): Document it. Reviewed-by: Maxim Cournoyer Change-Id: I1e29fe0977eb4f8026ee6a2d2f282e269c8c00b4 Reviewed-by: Maxim Cournoyer --- doc/guix.texi | 56 +++++++++++++++++++++++ gnu/services/shepherd.scm | 96 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 152 insertions(+) base-commit: 2afb48804e4ff829ed5ed97757fde0a2cd8e39fc diff --git a/doc/guix.texi b/doc/guix.texi index 278e610194b..0824bc5b0b7 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -45981,6 +45981,62 @@ Shepherd Services on the @code{timer} service. @end defvar +@cindex system log service, from Shepherd +@cindex syslogd, Shepherd system log service +@defvar shepherd-system-log-service-type +This service implements a @dfn{system log}, reading messages +applications send to @file{/dev/log} and writing them to files or +terminals according to user-defined rules. It provides functionality +traditionally implemented by @command{syslogd} programs. + +The value of services of this type must be a +@code{system-log-configuration} record, as described below. +@end defvar + +@c %start of fragment + +@deftp {Data Type} system-log-configuration +Available @code{system-log-configuration} fields are: + +@table @asis +@item @code{provision} (default: @code{(system-log syslogd)}) (type: list-of-symbols) +The name(s) of the system log service. + +@item @code{requirement} (default: @code{(root-file-system)}) (type: list-of-symbols) +Dependencies of the system log service. + +@item @code{kernel-log-file} (type: gexp-or-string-or-false) +File from which kernel messages are read, @file{/dev/kmsg} by default. + +@item @code{message-destination} (default: @code{#f}) (type: gexp-or-false) +This gexp must evaluate to a procedure that, when passed a log message, +returns the list of files to write it to; @code{#f} is equivalent to +using @code{(default-message-destination-procedure)}. @xref{System Log +Service,,,shepherd,The GNU Shepherd Manual}, for information on how to +write that procedure. + +@item @code{date-format} (type: gexp-or-string) +String or string-valued gexp specifying how to format timestamps in log +file. It must be a valid string for @code{strftime} (@pxref{Time,,, +guile,GNU Guile Reference Manual}), including delimiting space---e.g., +@code{"%c "} for a format identical to that of traditional syslogd +implementations. + +@item @code{history-size} (type: gexp-or-integer) +Number of logging messages kept in memory for the purposes of making +them available to @command{herd status system-log}. + +@item @code{max-silent-time} (type: gexp-or-integer) +Time after which a mark is written to log files if nothing was logged +during that time frame. + +@end table + +@end deftp + + +@c %end of fragment + @defvar %shepherd-root-service This service represents PID@tie{}1. @end defvar diff --git a/gnu/services/shepherd.scm b/gnu/services/shepherd.scm index 52588c04e31..cfbb3f1e30a 100644 --- a/gnu/services/shepherd.scm +++ b/gnu/services/shepherd.scm @@ -31,6 +31,7 @@ (define-module (gnu services shepherd) #:use-module ((guix diagnostics) #:select (define-with-syntax-properties formatted-message)) #:use-module (gnu services) + #:use-module (gnu services configuration) #:use-module (gnu services herd) #:use-module (gnu packages admin) #:use-module (ice-9 match) @@ -84,6 +85,17 @@ (define-module (gnu services shepherd) shepherd-timer-service-type shepherd-transient-service-type + system-log-configuration + system-log-configuration? + system-log-configuration-provision + system-log-configuration-requirement + system-log-configuration-message-destination + system-log-configuration-date-format + system-log-configuration-history-size + system-log-configuration-max-silent-time + + shepherd-system-log-service-type + assert-valid-graph)) ;;; Commentary: @@ -658,3 +670,87 @@ (define shepherd-transient-service-type This runs @command{rsync} in the background, as a service that you can inspect with @command{herd status} and stop with @command{herd stop}."))) + + +;;; +;;; System log. +;;; + +(define (gexp-or-false? x) + (or (gexp? x) (not x))) + +(define (gexp-or-integer? x) + (or (gexp? x) (integer? x))) + +(define (gexp-or-string? x) + (or (gexp? x) (string? x))) + +(define (gexp-or-string-or-false? x) + (or (gexp-or-string? x) (not x))) + +(define-configuration/no-serialization system-log-configuration + (provision + (list-of-symbols '(system-log syslogd)) + "The name(s) of the system log service.") + (requirement + (list-of-symbols '(root-file-system)) + "Dependencies of the system log service.") + (kernel-log-file + (gexp-or-string-or-false #~(kernel-log-file)) + "File from which kernel messages are read, @file{/dev/kmsg} by default.") + (message-destination + (gexp-or-false #f) + "This gexp must evaluate to a procedure that, when passed a log message, +returns the list of files to write it to; @code{#f} is equivalent to using +@code{(default-message-destination-procedure)}. @xref{System Log Service,,, +shepherd, The GNU Shepherd Manual}, for information on how to write that +procedure.") + (date-format + (gexp-or-string #~default-logfile-date-format) + "String or string-valued gexp specifying how to format timestamps in log +file. It must be a valid string for @code{strftime} (@pxref{Time,,, guile, +GNU Guile Reference Manual}), including delimiting space---e.g., @code{\"%c +\"} for a format identical to that of traditional syslogd implementations.") + (history-size + (gexp-or-integer #~(default-log-history-size)) + "Number of logging messages kept in memory for the purposes of making them +available to @command{herd status system-log}.") + (max-silent-time + (gexp-or-integer #~(default-max-silent-time)) + "Time after which a mark is written to log files if nothing was logged +during that time frame.")) + +(define shepherd-system-log-service-type + (shepherd-service-type + 'shepherd-system-log + (lambda (config) + (match-record config + (provision requirement message-destination + date-format history-size max-silent-time) + (shepherd-service + (documentation "Shepherd's built-in system log (syslogd).") + (provision (system-log-configuration-provision config)) + (requirement (system-log-configuration-requirement config)) + (modules '((shepherd service system-log) + ((shepherd support) #:select (default-logfile-date-format)) + ((shepherd logger) #:select (default-log-history-size)))) + (free-form + #~(system-log-service #:provision '#$provision + #:requirement '#$requirement + + ;; XXX: As of Shepherd 1.0.1, + ;; 'default-message-destination-procedure' is not + ;; exported, hence this conditional. + #$@(match message-destination + (#f #~()) + (value #~(#:message-destination #$value))) + + #:date-format #$date-format + #:history-size #$history-size + #:max-silent-time #$max-silent-time))))) + (system-log-configuration) + (description + "The Shepherd's @code{system-log} service plays the role of traditional +@command{syslogd} program, reading data logged by daemons to @file{/dev/log} +and writing it to several files in @file{/var/log} according to user-provided +dispatching rules."))) From patchwork Thu Feb 13 23:10:11 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 38578 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 5E33E27BBE2; Thu, 13 Feb 2025 23:11:37 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-8.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL, RCVD_IN_VALIDITY_SAFE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id E29DA27BBEB for ; Thu, 13 Feb 2025 23:11:36 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tiiMN-0007SS-BS; Thu, 13 Feb 2025 18:11:07 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiMK-0007S5-96 for guix-patches@gnu.org; Thu, 13 Feb 2025 18:11:04 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tiiMJ-0001dV-Uq; Thu, 13 Feb 2025 18:11:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=4iJLBwKETYup+huQLayN/kTJuoCYEmXGgkn3R7q/ysI=; b=Y5hS6N7B7ic/j5UMhCDSQtQ/uru+w2Ho8DKYC82QWw4gWWhq3K8g7Dm0aMQ6eMrY2ZdGTXS8SGxpody0PkXzNhQcu+dWQ735MVaRIWvJQLRqb4/OXP6S5ZZWDi14q1TOJPIBJcoGnHHDF9Co52UUvjFwWmx/8Lb9ucdThxvlxv9V+WNnvr1XE1vS+Phw997QAvB01CnNK9JGkVkNT5vdyc3JaURXGnErh+gT1u8oS4V2D0f6nrpzumFAjyyLuhsU3ibK/y7cOsvUFIMU2xd4lOvNmzwfyasGJrSayv+x5LLAg3+raduY7Ql3wcf38f18JTAoexh7Y/AS2MG/a5MwJA==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tiiMI-00029W-PF; Thu, 13 Feb 2025 18:11:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#76063] [PATCH v2 2/3] services: Switch to =?utf-8?q?=E2=80=98s?= =?utf-8?q?hepherd-system-log-service-type=E2=80=99?= in =?utf-8?b?4oCYJWJh?= =?utf-8?b?c2Utc2VydmljZXPigJku?= Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: ludo@gnu.org, maxim.cournoyer@gmail.com, guix-patches@gnu.org Resent-Date: Thu, 13 Feb 2025 23:11:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76063 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 76063@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer , Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer X-Debbugs-Original-Xcc: Ludovic =?utf-8?q?Court=C3=A8s?= , Maxim Cournoyer Received: via spool by 76063-submit@debbugs.gnu.org id=B76063.17394882468237 (code B ref 76063); Thu, 13 Feb 2025 23:11:02 +0000 Received: (at 76063) by debbugs.gnu.org; 13 Feb 2025 23:10:46 +0000 Received: from localhost ([127.0.0.1]:46086 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tiiM2-00028m-9n for submit@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44672) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tiiLw-000288-GD for 76063@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:41 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiLr-0001bQ-5Y; Thu, 13 Feb 2025 18:10:35 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=4iJLBwKETYup+huQLayN/kTJuoCYEmXGgkn3R7q/ysI=; b=lFwXCfdeokkFvdyqNc5H hVttlLUBWPq0klHoO2QcLkXTN5jw6+KcI7pUVNPsMMXngbmCIRLdqvzqW0XlvSiWazkzHwLRNY9l0 uTT5wd0mUJpQyLdXWNNSOusLOs/Wu1o+Q7CvsB2QCfntyIyNxGoFYaWtwcRuUmQf5rGAN1xAPliBR nveoVGZG+PILSFZNjdlN++Ao+wy2WLjZW3oZJLJzB1J8yDBTe44kKJivayPP/ysHZcJI8qAjPkG9q /GzrCqzifE3z2jod2GLtorg6AAcVR79t/oTsCVv1+31M6wYMIFFdJ9Ht1gt0ZJbX2qL7QMhyg+sSe 00ZaIqWws8LvFA==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Fri, 14 Feb 2025 00:10:11 +0100 Message-ID: X-Mailer: git-send-email 2.48.1 In-Reply-To: <55515c28a50da000da09f7cdb38f3efaf19f0236.1739488125.git.ludo@gnu.org> References: <55515c28a50da000da09f7cdb38f3efaf19f0236.1739488125.git.ludo@gnu.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/services/base.scm (%base-services): Replace ‘syslog-service-type’ by ‘shepherd-system-log-service-type’. * doc/guix.texi (Base Services): Update ‘syslog-service-type’ documentation. (Shepherd Services): Mention that ‘system-log-service-type’ is in ‘%base-services’. Add anchor. Reviewed-by: Maxim Cournoyer Change-Id: I21082300f6a052865a6ab1bdff27fbe71f73d492 Reviewed-by: Maxim Cournoyer --- doc/guix.texi | 17 +++++++++++++---- gnu/services/base.scm | 2 +- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 0824bc5b0b7..54c365abf3b 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -19880,11 +19880,17 @@ Base Services external name servers do not even need to be queried. @end defvar -@cindex syslog -@cindex logging +@cindex syslog, with external syslogd +@cindex logging, syslog @defvar syslog-service-type -Type of the service that runs the syslog daemon, whose value is a -@code{} object. +Type of the service that runs the syslog daemon (@command{syslogd}), +whose value is a @code{} object (see below). + +@quotation Note +This service is redundant with and for the most part superseded by +@code{shepherd-system-log-service-type} (@pxref{shepherd-system-log, the +Shepherd system log}). +@end quotation @end defvar To have a modified @code{syslog-configuration} come into effect after @@ -45981,6 +45987,7 @@ Shepherd Services on the @code{timer} service. @end defvar +@anchor{shepherd-system-log} @cindex system log service, from Shepherd @cindex syslogd, Shepherd system log service @defvar shepherd-system-log-service-type @@ -45991,6 +45998,8 @@ Shepherd Services The value of services of this type must be a @code{system-log-configuration} record, as described below. + +This service is part of @code{%base-services} (@pxref{Base Services}). @end defvar @c %start of fragment diff --git a/gnu/services/base.scm b/gnu/services/base.scm index 4bc0433def6..684de754e6d 100644 --- a/gnu/services/base.scm +++ b/gnu/services/base.scm @@ -3931,7 +3931,7 @@ (define %base-services (cons tty %default-console-font)) '("tty1" "tty2" "tty3" "tty4" "tty5" "tty6"))) - (service syslog-service-type) + (service shepherd-system-log-service-type) (service agetty-service-type (agetty-configuration (extra-options '("-L")) ; no carrier detect (term "vt100") From patchwork Thu Feb 13 23:10:12 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 38576 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 6816127BBEA; Thu, 13 Feb 2025 23:11:19 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-8.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2,RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL, RCVD_IN_VALIDITY_SAFE,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id CA1DB27BBE2 for ; Thu, 13 Feb 2025 23:11:17 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tiiMO-0007T2-Hv; Thu, 13 Feb 2025 18:11:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiMM-0007SQ-7G for guix-patches@gnu.org; Thu, 13 Feb 2025 18:11:06 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tiiML-0001di-Jg for guix-patches@gnu.org; Thu, 13 Feb 2025 18:11:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=TCrEm5e5bInYcFD0FKJ4HxXbMZ5ZcNOV1HAWiGFYyfk=; b=Z5N4uuEJgSLvgycIEuLUjoWS1r8NNsA4qJ/swejzeT3F+TCVFIftFFWtNeuNtcUQW/lOL2XS1KcAs0Qu/M/4zsVZE5cnuEhDESDHe8NrPd1jgY460KQu0o+tt6nTJ333OQvlCEq9n2z3EbjnFBSXIxZ6kEZjwP/F10HmzMCobx74EJMu9bAAWExYpD8c+9jZLlz/NcJgUPDBDjGxTVqk6pDUXWahpiQ6JUE6t3fkNbw9IwRc+a7XSHGI4TkppbdM3cfyqDoG3Tl8OF6JP0G1uxWDfB2awuvlBwHvH1vlBj3tpoS9yylMNeBGpuFgbD2j9dDZpSSz/+Vtut6D3TU9jQ==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tiiMJ-00029e-61; Thu, 13 Feb 2025 18:11:03 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#76063] [PATCH v2 3/3] DRAFT: news: Add entry for =?utf-8?b?4oCYc3lzdGVtLWxvZ+KAmQ==?= switch. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: pelzflorian@pelzflorian.de, julien@lepiller.eu, guix-patches@gnu.org Resent-Date: Thu, 13 Feb 2025 23:11:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 76063 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 76063@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Florian Pelz , Maxim Cournoyer , Florian Pelz , Julien Lepiller X-Debbugs-Original-Xcc: Florian Pelz , Julien Lepiller Received: via spool by 76063-submit@debbugs.gnu.org id=B76063.17394882478244 (code B ref 76063); Thu, 13 Feb 2025 23:11:03 +0000 Received: (at 76063) by debbugs.gnu.org; 13 Feb 2025 23:10:47 +0000 Received: from localhost ([127.0.0.1]:46088 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tiiM2-00028o-Po for submit@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:47 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:44676) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1tiiLy-00028B-5f for 76063@debbugs.gnu.org; Thu, 13 Feb 2025 18:10:42 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tiiLs-0001bc-De; Thu, 13 Feb 2025 18:10:36 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=TCrEm5e5bInYcFD0FKJ4HxXbMZ5ZcNOV1HAWiGFYyfk=; b=agHu2D3tZ9Obe3iDAnDC t6pAkCUs2nT+pKRgeq6+nqTqUSefqTfDaD4cJtcn5Li3EfEob+rCcdz5NGg5NW1MhmYcEYHL5OrYY LfSbQpBG8Ohj2HMti6T8yoPT7UJlBbXJnGnJJxVbQ4r6P3MDWT541FvM20914xO6Wgl7qRiozMgP7 8yn7GZ+1mVWwTq7/Pjdp9TSsXZNCXSpjN+6lfhvFvQGhGgL07f02I7xAOi7Cw6RlvuyFrHwzh4eic ZHG+4uO1s3PL1Vm3aMn7PJk31KvHohBt8R9BKAeWViySf3QnP8MVS6IPTg6mLN1/FeBYP5hKd2nGh EpQi2TT00aS5Yg==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Fri, 14 Feb 2025 00:10:12 +0100 Message-ID: <74d1933fcc18944d3a5f03cc08e53141710e21c9.1739488125.git.ludo@gnu.org> X-Mailer: git-send-email 2.48.1 In-Reply-To: <55515c28a50da000da09f7cdb38f3efaf19f0236.1739488125.git.ludo@gnu.org> References: <55515c28a50da000da09f7cdb38f3efaf19f0236.1739488125.git.ludo@gnu.org> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches DRAFT: Update commit ID. * etc/news.scm: Add entry. Reviewed-by: Maxim Cournoyer Co-authored-by: Florian Pelz Change-Id: Ie3d827741a01c95f2bea908b57c707342e8f2386 Reviewed-by: Maxim Cournoyer --- etc/news.scm | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/etc/news.scm b/etc/news.scm index 106a58a2b0a..8c9e1634890 100644 --- a/etc/news.scm +++ b/etc/news.scm @@ -37,6 +37,43 @@ (channel-news (version 0) + (entry (commit "TODO") + (title + (en "Guix System switches to the Shepherd's system log") + (de "Guix System wechselt zu Shepherds Systemprotokoll") + (fr "Guix System passe au journal système de Shepherd") + (body + (en "The default system log used on Guix System and part of +@code{%base-services} has been switched from the @command{syslogd} command of +GNU@tie{}Inetutils to the new built-in @code{system-log} service found in +version 1.0 of the Shepherd. + +The advantages of this change are the fact that @code{system-log} can start +logging earlier after boot and stop shortly before shutdown, along with full +integration with the rest of @command{shepherd}, in particular with the new +@code{log-rotation} service.") + (de "Das vorgegebene Systemprotokoll, das auf Guix System benutzt +wird und Teil von @code{%base-services} ist, wurde ausgetauscht und anstelle +des Befehls @command{syslogd} aus den GNU@tie{}Inetutils wird der neue, in +Version 1.0 von Shepherd eingebaute @code{system-log}-Dienst benutzt. + +Die Vorteile dieser Änderung sind, dass @code{system-log} schon früher nach +dem Start Protokolle aufnehmen kann, kurz vor dem Herunterfahren damit aufhört +und außerdem mit dem Rest von @command{shepherd} voll integriert ist, +insbesondere mit dem neuen Dienst @code{log-rotation} zur +Protokollrotation.") + (fr "Le journal système par défaut sur Guix System, qui fait partie +de @code{%base-services}, est passé de la commande @command{syslogd} de +GNU@tie{}Inetutils au nouveau service @code{system-log} fourni par la version +1.0 du Shepherd. + +Les avantages de ce changement sont le fait que @code{system-log} peut +commencer à enregistrer les journaux plus tôt pendant la séquence de +démarrage et s'arrêter plus tard au moment de l'arrêt, ainsi que son +intégration complète avec le reste de @command{shepherd}, en particulier avec +le nouveau service @code{log-rotation}.")))) + + (entry (commit "0753a17ddf6f4fab98b93c25f1a93b97ff9e46bb") (title (en "The @command{guix deploy} command now supports the Hetzner Cloud