From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id 2EPSKuL+K2cQjQAAqHPOHw:P1 (envelope-from ) for ; Wed, 06 Nov 2024 23:42:26 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id 2EPSKuL+K2cQjQAAqHPOHw (envelope-from ) for ; Thu, 07 Nov 2024 00:42:26 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=wolfsden.cz header.s=mail header.b="He6/6eiT"; dkim=pass header.d=wolfsden.cz header.s=mail header.b=NZ+Wywe2; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=wolfsden.cz ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1730936546; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=iGpPsz9krBODSWM//us5AO8D+BK2/RoHen/oSlQ6oIQ=; b=EuSm7LBwfIRXm+NWjiDwfIRY0KFBD3zfADZP2JYGvMSM1K/FAW7oV9pZzFPNFcYselA17y VklArPf8HeVs9qG2NGxci/eDhtTV1iOP5e4bzYGlpfu3QOlBzFqUkuwIvpHrpgQ0ah+Chr BBHv9n+Qy7ozYYvhlvRsBbeoP3zS/Wz0DmCdY0jPr8f3gyaU+t7XDfRSteifhKL8SpGeXP nWpf3ogefEVQDPb3LdPSxuGUSDdPF8V8OfqsGR9DR+ZJPi2UsKWY3GMGuvqTS3R7LU2U0c prJzTnlZaH0RTa83NQ8upLpLJtw9nOtb28pX4jOSLxLwkxsfBz3UtO0c0D5R2A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=wolfsden.cz header.s=mail header.b="He6/6eiT"; dkim=pass header.d=wolfsden.cz header.s=mail header.b=NZ+Wywe2; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=wolfsden.cz ARC-Seal: i=1; s=key1; d=yhetil.org; t=1730936546; a=rsa-sha256; cv=none; b=nPsn/KTMk2cqzIErCmLHPSL9wic8zh4YAaI5YNAK7V+/nWHUqg/Ecl57FxIsiQL4GST2R7 aJ+NeEysT2hcypP0za2AuB8/EzjHC10tIHgc7M2wR8TXEBgiwI+wBuh2wMlGScW1XiOkx7 GrlY4b+25t9RVVY8nsoDlPm92kkoyuxOylacNyRxtJmi9yvEir2PpEu3PLvRniyBjNDLiE 4NLmphdGM6m482lgT80BgBWFHocddAmD7VLR96oE8EJqRlUZtR29A5CiQRt/V/0VYJA+I3 F81UerW8RC6EeHyxnD+AFdVw/KLqkgDSzkG8Vd2+yOzWwLAsp1rkcA6S0WV/pw== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 64EDC8927A for ; Thu, 07 Nov 2024 00:42:25 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t8peq-0004q5-M3; Wed, 06 Nov 2024 18:41:52 -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 <~@wolfsden.cz>) id 1t8peo-0004pu-Mz for help-guix@gnu.org; Wed, 06 Nov 2024 18:41:50 -0500 Received: from wolfsden.cz ([37.205.8.62]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <~@wolfsden.cz>) id 1t8pem-00057x-EG for help-guix@gnu.org; Wed, 06 Nov 2024 18:41:50 -0500 Received: by wolfsden.cz (Postfix, from userid 104) id 4479A310123; Wed, 6 Nov 2024 23:41:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1730936504; bh=dlrNBSneYdojAPmL67vgtCE4D8BXXtVvv4TQP1kltfw=; h=From:To:Subject:Date; b=He6/6eiTd1vSU/f7xhfhaZcCYy5KmP4KUUg5irRmNTa2PlEIb2d+WUGkfmWLBEbHY 61R6FVVHP6fBXSOmalVukHi0bvl0v9UmAQTg+V+QfaydwB3l2OZY5/54Ydz6N3SrUo BOL8XgVx+Hnq0Ttgf2f///YXUjpF6XMrMAdEgx6LuUIK4HaLK1pbmq5xM0VYihzQQ8 2qG8ODuSviLEBVmYAx926ur8PTayPVHOOCekhda9/x1HwOUhRaWD+MMFrcR+ut/Tnl kW5JjCoCYQTsZmLTaKgsjLPLryqVtk23l3hCEVbpvsY66p3QpIFk2iyEmnzALgSWhb H8MuSih6D0/VopsylD89DL0l9dmZkNvPxSNzAAAdD8hvdQG3E9TeU5liEMmCYN3AT3 1qiO8151B8yUi4g7utjVQJcUniAw5G2TF7dqESo79qp6qUbsgLSouJqaCsbOUfNco3 hSZZyZjlTK3RqaTfMWxg094tyRh3CDU921zNp7UOVlFu9fWT4wNUi1XH5tkdILqeot K7NqAO2D2cPnYFn1sVe8bi6j4ONfjeHYtCGOPFh1mp4OBk2S+G54YETwtVYkEv+H44 Q74yJPSFOhax4WeAfPWfZmbwNOzYC25Hsos12URzUFev2u1Iy2jQ1YZVVUXhzEELCS QRjaSqCVFjY/fk/6f4oxSzAA= Received: from localhost (unknown [128.0.188.242]) by wolfsden.cz (Postfix) with ESMTPSA id 6924E34F3A7 for ; Wed, 6 Nov 2024 23:41:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=wolfsden.cz; s=mail; t=1730936503; bh=dlrNBSneYdojAPmL67vgtCE4D8BXXtVvv4TQP1kltfw=; h=From:To:Subject:Date; b=NZ+Wywe2fjfFmvZOIxSwjgrGsMdEjvs6VCb/L4TCAU45AyrACPfhwANXR2UuQ4bN/ vNG8l1/khyok+eUNqMSrluk6xLJTiRrmH21qtvqiy/+VCts+uPloCp+FUw1kuxRJgV nSXPhktcsltRRBYW4pacSv2Bj268wL3VtlfBKPj9npSZCdanA0HQnI38z2WkYXFlzP +5yHNKwjwwRYUjOBpuw0A7VuO9AZQSfWh2CvgVpN3mMCHqp9HW0LFSCeHqg9mVgsPn l2Wd7An7Wfu25ApYdqQwp6Cz6jgQhUtdQfLbGO+1Z5ybM6zQMe6qa8y30+yioKP0CB CSTRsgSTPo2xn8+kuhrQ4X9FykEMu5/UXWBx1N7bIwVNn9bTN9r5WavUUZf6MQD5oo j8Md0BomnlKOKSE7UXcMMdiXY4L9fmXLpnwgCwHgm+RjmatiWpMOIIm/wgMIiS4sCL aYs86h4hC1jetziC+TJM+Kc4hn4FZDdH0iN0XX3uI192FSJP0P0tcqnnHeWas76wGW NNLP6o/gVBEg6ynUIc7NM8sazogzhHAYvUXH+fYbtlyQOkvQ45VWTRr4JHFsB2FPMO F90dcLUM6p7ua9CdRpoYzbwXn2KWBBWgvU4m3tyiMk/RjyAUsVSzPa7jgWErtDuchh M5KB9KETuwTOnfBTW9mIVA4I= From: Tomas Volf <~@wolfsden.cz> To: help-guix@gnu.org Subject: Why is my shepherd service not getting respawned? Mail-Followup-To: help-guix@gnu.org Date: Thu, 07 Nov 2024 00:41:42 +0100 Message-ID: <87fro4aq15.fsf@wolfsden.cz> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Received-SPF: pass client-ip=37.205.8.62; envelope-from=~@wolfsden.cz; helo=wolfsden.cz X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: -1.77 X-Spam-Score: -1.77 X-Migadu-Queue-Id: 64EDC8927A X-TUID: QacUGbg3dajO --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hello all. (To prevent XY problem:) I want to auto-mount NFS file-system, and the built-in =2D-8<---------------cut here---------------start------------->8--- (shepherd-requirements '(networking)) =2D-8<---------------cut here---------------end--------------->8--- does not work for me (but let us not get distracted by that). I wrote a shepherd service to function as a check for networking being actually up, but it does not get respawned when it fails and I do not understand why. This is the service in my operating-system: =2D-8<---------------cut here---------------start------------->8--- (simple-service 'network-online shepherd-root-service-type (list (shepherd-service (requirement '(networking)) (provision '(network-online)) (documentation "Wait for the network to come up.") (start #~(lambda _ (let* ((cmd "/run/privileged/bin/ping -qc1 -W1 1.1.1.1") (status (system cmd))) (=3D 0 (status:exit-val status))))) (one-shot? #t) ;; Try every second. (respawn-delay 1) ;; Retry forever. Double-quoting is intentional. (respawn-limit ''(5 . 5))))) =2D-8<---------------cut here---------------end--------------->8--- Now, when I reboot the machine, I see in the log that the service did start: =2D-8<---------------cut here---------------start------------->8--- Nov 7 00:18:20 localhost shepherd[1]: Starting service network-online... [..] Nov 7 00:18:20 localhost shepherd[1]: [sh] PING 192.168.0.110 (192.168.0.1= 10): 56 data bytes Nov 7 00:18:20 localhost shepherd[1]: [sh] /run/privileged/bin/ping: sendi= ng packet: Network is unreachable Nov 7 00:18:20 localhost shepherd[1]: Service network-online could not be = started. Nov 7 00:18:20 localhost shepherd[1]: Service network-online failed to sta= rt. =2D-8<---------------cut here---------------end--------------->8--- The fail on first run is expected, however the problem is it starts exactly once. I do not see any attempts to respawn it in the /var/log/messages, but based on the documentation the service *should* get respawned, since it failed. What am I doing wrong? Would anyone have any suggestions, either what is wrong with the code above or how to approach it in another way? Thank you and have a nice day, Tomas =2D-=20 There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJCBAEBCgAsFiEEt4NJs4wUfTYpiGikL7/ufbZ/wakFAmcr/rYOHH5Ad29sZnNk ZW4uY3oACgkQL7/ufbZ/wak2OBAAqhF34Ql5gEsIwd45Ge0uhvnaw87a//xo/kge gxn6DYqnaNxQ3Nr1dTXaUeitVnNmArZ5fPGdLOTxO64nrS7bSKQMjVXdpCuR8ShG NWuh/MEsOmAsGn8jSCJqMhECyt34ma6m1dfHEKexw5W1k+2Del0wleVCNDaJbAX4 SjbvmyPmIMnqTgwOXZOuiFDlr/sedcRO2TFOMWNFPj8aqbPcmogb7s14HLFqWQMo lqmdYRpewk1sBcytIJ6NRKg/O0Rk/aklcUDgiNJlA8pxyTJCwzx76ni70S2Zese/ sQN9BYRJ74wTcN5PYwzMXQuqo7Fj7ecYFgbH7ba9CPl2Tw3GD/P/rCE8L48vUaGh /S2Sf0E/E7vE5Gdc8lcRaK90tueM/62y4vbWdeHirLyqUR4wZZ/GIT7aqQ+zRN71 hGEdMtd2AFGnLUBWxZbbeH85msEF8k8nNPKKzboyaZHCVBlN95aQ6VIJUBbLEuf4 Mf4fQ26SoV85B80hCPoakIQRl36b2DNV1hnOZaoIDEHOcb6UM7TUxNGaf4ZamjXF 7xYoGhwRxWeEIyst6fNl2qmdI5ZH6MyMj0QeSrWd/9sEIr01J13VikfO3zPPTmos 9+v2rR3npil3yLEdgAl9fsMOlrX5kE1En+HD7EqZ5wGw2sBslCWwlb25/k9YzKZ+ 5BjvNsg= =6BGY -----END PGP SIGNATURE----- --=-=-=--