From mboxrd@z Thu Jan 1 00:00:00 1970 From: rendaw <7e9wc56emjakcm@s.rendaw.me> Subject: Services and log management/monitoring Date: Mon, 15 Apr 2019 03:12:23 +0900 Message-ID: <67f09d8d-3ca6-90a0-6e72-c85ec9d1572f@s.rendaw.me> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([209.51.188.92]:50210) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <7e9wc56emjakcm@s.rendaw.me>) id 1hFjcE-0007Zs-Bn for help-guix@gnu.org; Sun, 14 Apr 2019 14:12:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <7e9wc56emjakcm@s.rendaw.me>) id 1hFjcD-0003R3-Aq for help-guix@gnu.org; Sun, 14 Apr 2019 14:12:30 -0400 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:49755) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from <7e9wc56emjakcm@s.rendaw.me>) id 1hFjcB-0003Pi-H8 for help-guix@gnu.org; Sun, 14 Apr 2019 14:12:28 -0400 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 9264E20EB0 for ; Sun, 14 Apr 2019 14:12:26 -0400 (EDT) Received: from [192.168.1.35] (y236169.dynamic.ppp.asahi-net.or.jp [118.243.236.169]) by mail.messagingengine.com (Postfix) with ESMTPA id AC85C10316 for ; Sun, 14 Apr 2019 14:12:25 -0400 (EDT) Content-Language: en-US List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: help-guix@gnu.org The manual talks about standard services vs shepherd services, but doesn't really discuss which either are. My impression is a standard service is simply a process guix runs on the system (at startup, based on the graph?), where a shepherd service is a process that is managed (may be manually started/stopped, automatically restarted, is watched) by shepherd. Is that interpretation correct? My expectation would then be that you should generally use shepherd services, except when you want very fine control over how the service is managed. Do shepherd services automatically get enabled and start when configured in a guix config? Okay, just reread everything and I'm quite confused. It says shepherd is pid 1, so "shepherd" services are the more fundamental service type? But the manual says that shepherd services are a particular type of service, which implies the opposite. Why would one use "service" instead of "shepherd-service" (or vice-versa)? Is it possible to define a service which depends on a shepherd-service? What about the reverse? -- On logging - one of the things I like about systemd is that all services log their stdout/err and there's a standard way to retrieve logs, and especially query logs from a particular time range/boot. It also exposes dbus events when service statuses change - so it's pretty easy to send a notification if a service dies for instance, maybe with the logs from the 10m leading up to the issue. I couldn't find anything about logging and monitoring in the guix manual (other than statistic collecting agents/dashboards). In the shepherd manual all I could find was a note that services send stdout/stderr to syslog. Are any of the above possible with this setup? I've used syslog systems for years up until systemd, but my impression was that it was basically a pile of random files you can read manually if you really must. Do non-shepherd services also log somewhere?