Message ID | 20240327051520.8231-4-stefan.schantl@ipfire.org |
---|---|
State | Superseded |
Headers |
Return-Path: <development-bounces@lists.ipfire.org> Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4V4FHs4Hn4z3wxX for <patchwork@web04.haj.ipfire.org>; Wed, 27 Mar 2024 05:15:53 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4V4FHp1tsXz5Yr; Wed, 27 Mar 2024 05:15:50 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4V4FHn5Phlz30VB; Wed, 27 Mar 2024 05:15:49 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4V4FHj4FtBz30Gj for <development@lists.ipfire.org>; Wed, 27 Mar 2024 05:15:45 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4V4FHj1RMWz5WG; Wed, 27 Mar 2024 05:15:45 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1711516545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=hNdPL+VwBUbN3gYd19Zw+vuTZunVobPXdzOXlSe4JEQ=; b=3wsqW1iYFAnkHkcqhMJ72HjjsIumH2/QJfrfScc6ZaKQ8jx6SCiGOo+T4sZ6ADSDD+Rxob WJ1GXn51h3n+/VBQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1711516545; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=hNdPL+VwBUbN3gYd19Zw+vuTZunVobPXdzOXlSe4JEQ=; b=b1j6W3iHbW98qh1MsQLVaHk29KbrrB3jrc/PhxF2pD3VRuO35KyfRBXhbxUi3s8pIO+Ei4 QIF05YlbsZdVZ2S5T2aNJY7VdTn9/a/m9nuKtBFrezqd7vB7cUZLIsPW0H8ZLs7OmoxMqB ItdHoDcBR+xhXCCVlwWTzZC4TC6pmIgek3vWJ+5faWAhzxhZNfPQh+cSrbM26PHm017BuD RwM81ZAsAVaXkbL5WhC0cEPl6ezXocHKfGbstUvPZctl9Wx5WI7YPG2qd/OZ4PoTVItJEo 3tNegJKFjMUk2hfhZqzDneaaleZkmNHEHm2dYZriAapO8x9e35PA2dLlfkxLNg== From: Stefan Schantl <stefan.schantl@ipfire.org> To: development@lists.ipfire.org Subject: [PATCH 4/4] grub-btrfsd: Drop redundant used PIDFILE mechanism Date: Wed, 27 Mar 2024 06:15:20 +0100 Message-Id: <20240327051520.8231-4-stefan.schantl@ipfire.org> In-Reply-To: <20240327051520.8231-1-stefan.schantl@ipfire.org> References: <D08FA2D0-9361-40D6-9CBF-6C48DE0BF809@ipfire.org> <20240327051520.8231-1-stefan.schantl@ipfire.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: GRXNJTZAJ4LEUEITJMHIOUXRKLOUF6GW X-Message-ID-Hash: GRXNJTZAJ4LEUEITJMHIOUXRKLOUF6GW X-MailFrom: stefan.schantl@ipfire.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: IPFire development talk <development.lists.ipfire.org> Archived-At: <https://lists.ipfire.org/hyperkitty/list/development@lists.ipfire.org/message/GRXNJTZAJ4LEUEITJMHIOUXRKLOUF6GW/> List-Archive: <https://lists.ipfire.org/hyperkitty/list/development@lists.ipfire.org/> List-Help: <mailto:development-request@lists.ipfire.org?subject=help> List-Owner: <mailto:development-owner@lists.ipfire.org> List-Post: <mailto:development@lists.ipfire.org> List-Subscribe: <mailto:development-join@lists.ipfire.org> List-Unsubscribe: <mailto:development-leave@lists.ipfire.org> |
Series |
[1/4] initscripts: Add generic function to get the filesystem type of a volume
|
|
Commit Message
Stefan Schantl
March 27, 2024, 5:15 a.m. UTC
This case is already covered by the PID mechanism of the used functions
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
---
src/initscripts/system/grub-btrfsd | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
Comments
> On 27 Mar 2024, at 05:15, Stefan Schantl <stefan.schantl@ipfire.org> wrote: > > This case is already covered by the PID mechanism of the used functions > > Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org> > --- > src/initscripts/system/grub-btrfsd | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/src/initscripts/system/grub-btrfsd b/src/initscripts/system/grub-btrfsd > index 26760f9be..5981c3a0a 100644 > --- a/src/initscripts/system/grub-btrfsd > +++ b/src/initscripts/system/grub-btrfsd > @@ -33,15 +33,14 @@ case "$1" in > btrfs) > > boot_mesg "Starting GRUB/Btrfs Daemon..." > - loadproc -b -p "$PIDFILE" /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" > - echo "$!" > "$PIDFILE" > + loadproc -b /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" > ;; > esac > ;; > > stop) > boot_mesg "Stopping grub-btrfsd..." > - killproc -p "$PIDFILE" /usr/bin/grub-btrfsd > + killproc -p /usr/bin/grub-btrfsd > sleep 1; Why is there a sleep here? > ;; > > -- > 2.39.2 >
Am Mittwoch, dem 27.03.2024 um 10:15 +0000 schrieb Michael Tremer: > > > > On 27 Mar 2024, at 05:15, Stefan Schantl > > <stefan.schantl@ipfire.org> wrote: > > > > This case is already covered by the PID mechanism of the used > > functions > > > > Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org> > > --- > > src/initscripts/system/grub-btrfsd | 5 ++--- > > 1 file changed, 2 insertions(+), 3 deletions(-) > > > > diff --git a/src/initscripts/system/grub-btrfsd > > b/src/initscripts/system/grub-btrfsd > > index 26760f9be..5981c3a0a 100644 > > --- a/src/initscripts/system/grub-btrfsd > > +++ b/src/initscripts/system/grub-btrfsd > > @@ -33,15 +33,14 @@ case "$1" in > > btrfs) > > > > boot_mesg "Starting GRUB/Btrfs Daemon..." > > - loadproc -b -p "$PIDFILE" /usr/bin/grub-btrfsd --syslog > > "$SNAPSHOTDIR" > > - echo "$!" > "$PIDFILE" > > + loadproc -b /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" > > ;; > > esac > > ;; > > > > stop) > > boot_mesg "Stopping grub-btrfsd..." > > - killproc -p "$PIDFILE" /usr/bin/grub-btrfsd > > + killproc -p /usr/bin/grub-btrfsd > > sleep 1; > > Why is there a sleep here? Good catch, that's a classical orphaned piece of code when removing some other stuff. I'll handle it in a v2 patchset. > > > ;; > > > > -- > > 2.39.2 > > >
It is almost as if there is something good about having this review process :) > On 27 Mar 2024, at 19:42, Stefan Schantl <stefan.schantl@ipfire.org> wrote: > > Am Mittwoch, dem 27.03.2024 um 10:15 +0000 schrieb Michael Tremer: >> >> >>> On 27 Mar 2024, at 05:15, Stefan Schantl >>> <stefan.schantl@ipfire.org> wrote: >>> >>> This case is already covered by the PID mechanism of the used >>> functions >>> >>> Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org> >>> --- >>> src/initscripts/system/grub-btrfsd | 5 ++--- >>> 1 file changed, 2 insertions(+), 3 deletions(-) >>> >>> diff --git a/src/initscripts/system/grub-btrfsd >>> b/src/initscripts/system/grub-btrfsd >>> index 26760f9be..5981c3a0a 100644 >>> --- a/src/initscripts/system/grub-btrfsd >>> +++ b/src/initscripts/system/grub-btrfsd >>> @@ -33,15 +33,14 @@ case "$1" in >>> btrfs) >>> >>> boot_mesg "Starting GRUB/Btrfs Daemon..." >>> - loadproc -b -p "$PIDFILE" /usr/bin/grub-btrfsd --syslog >>> "$SNAPSHOTDIR" >>> - echo "$!" > "$PIDFILE" >>> + loadproc -b /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" >>> ;; >>> esac >>> ;; >>> >>> stop) >>> boot_mesg "Stopping grub-btrfsd..." >>> - killproc -p "$PIDFILE" /usr/bin/grub-btrfsd >>> + killproc -p /usr/bin/grub-btrfsd >>> sleep 1; >> >> Why is there a sleep here? > Good catch, that's a classical orphaned piece of code when removing > some other stuff. > > I'll handle it in a v2 patchset. >> >>> ;; >>> >>> -- >>> 2.39.2
diff --git a/src/initscripts/system/grub-btrfsd b/src/initscripts/system/grub-btrfsd index 26760f9be..5981c3a0a 100644 --- a/src/initscripts/system/grub-btrfsd +++ b/src/initscripts/system/grub-btrfsd @@ -33,15 +33,14 @@ case "$1" in btrfs) boot_mesg "Starting GRUB/Btrfs Daemon..." - loadproc -b -p "$PIDFILE" /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" - echo "$!" > "$PIDFILE" + loadproc -b /usr/bin/grub-btrfsd --syslog "$SNAPSHOTDIR" ;; esac ;; stop) boot_mesg "Stopping grub-btrfsd..." - killproc -p "$PIDFILE" /usr/bin/grub-btrfsd + killproc -p /usr/bin/grub-btrfsd sleep 1; ;;