From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 2/2] Package nfs-utils: Start/stop daemons consistently
Date: Fri, 1 Jul 2016 14:46:25 +0200 [thread overview]
Message-ID: <20160701124625.GD25487@free.fr> (raw)
In-Reply-To: <1456485374-5356-2-git-send-email-universeII@gmx.de>
Andreas, All,
On 2016-02-26 12:16 +0100, Andreas Ehmanns spake thusly:
> Changed init script to start and stop all nfs daemons
> in a consistent way. Using the same kill command,
> start/stop the daemon, printout OK or FAIL and touch
> or deleted necessary files.
>
> Signed-off-by: Andreas Ehmanns <universeII@gmx.de>
> ---
> package/nfs-utils/S60nfs | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/package/nfs-utils/S60nfs b/package/nfs-utils/S60nfs
> index 0b78c9b..c9368b4 100755
> --- a/package/nfs-utils/S60nfs
> +++ b/package/nfs-utils/S60nfs
> @@ -27,7 +27,7 @@ start() {
> rpc.statd
> [ $? = 0 ] && echo "OK" || echo "FAIL"
> touch /var/lock/subsys/nfslock
> -
> +
Hmm... I missed that spurious change in your previous patch... :-/
> printf "Starting NFS services: "
> /usr/sbin/exportfs -r
> [ $? = 0 ] && echo "OK" || echo "FAIL"
> @@ -49,18 +49,18 @@ stop() {
> [ $? = 0 ] && echo "OK" || echo "FAIL"
>
> printf "Shutting down NFS daemon: "
> - kill -9 `pidof nfsd` 2>/dev/null
> + killall -q -9 nfsd 2>/dev/null
Since you said "stop all nfs daemons in a consistent way", why do we
need to killall -9 here, when we're not using it for the other two
daemons?
Regards,
Yann E. MORIN.
> [ $? = 0 ] && echo "OK" || echo "FAIL"
>
> printf "Shutting down NFS services: "
> /usr/sbin/exportfs -au
> - rm -f /var/lock/subsys/nfs
> - killall -q rpc.statd
> [ $? = 0 ] && echo "OK" || echo "FAIL"
>
> printf "Stopping NFS statd: "
> killall -q rpc.statd
> [ $? = 0 ] && echo "OK" || echo "FAIL"
> + rm -f /var/lock/subsys/nfs
> + rm -f /var/run/rpc.statd.pid
> rm -f /var/lock/subsys/nfslock
> }
>
> @@ -81,7 +81,7 @@ case "$1" in
> touch /var/lock/subsys/nfs
> ;;
> *)
> - echo "Usage: nfs {start|stop|reload}"
> + echo "Usage: $0 {start|stop|restart|reload}"
> exit 1
> esac
>
> --
> 2.1.4
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
next prev parent reply other threads:[~2016-07-01 12:46 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-26 11:16 [Buildroot] [PATCH 1/2] Package nfs-utils: Added check for OK/FAIL Andreas Ehmanns
2016-02-26 11:16 ` [Buildroot] [PATCH 2/2] Package nfs-utils: Start/stop daemons consistently Andreas Ehmanns
2016-07-01 12:46 ` Yann E. MORIN [this message]
2016-07-03 14:28 ` Maxime Hadjinlian
2016-07-01 12:41 ` [Buildroot] [PATCH 1/2] Package nfs-utils: Added check for OK/FAIL Yann E. MORIN
2016-07-03 13:13 ` Maxime Hadjinlian
2016-07-03 14:03 ` Peter Korsgaard
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160701124625.GD25487@free.fr \
--to=yann.morin.1998@free.fr \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox