From a1c04f2fb24cfc41c5b1803df986617100d467bb Mon Sep 17 00:00:00 2001 From: Ralph Ronnquist Date: Wed, 6 Jan 2021 19:07:24 +1100 Subject: [PATCH] corrected renice handling --- rrqnet-ifupdown.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/rrqnet-ifupdown.sh b/rrqnet-ifupdown.sh index 98d97e7..2789695 100755 --- a/rrqnet-ifupdown.sh +++ b/rrqnet-ifupdown.sh @@ -45,6 +45,8 @@ configure_tap_up() { start_cable_pre_up() { configure_tap_up || return 1 configure_tap_bridge || return 1 + [ -z "$IF_RRQNET_RENICE" ] || \ + RRQDAEMON="/usr/bin/nice -n $IF_RRQNET_RENICE $RRQDAEMON" if [ -z "$IF_RRQNET_LOG" ] ; then daemon -U -r -n $NAME -- \ $RRQDAEMON $IF_RRQNET_OPTIONS \ @@ -54,9 +56,6 @@ start_cable_pre_up() { $RRQDAEMON ${IF_RRQNET_LOG%% *} $IF_RRQNET_OPTIONS \ -t $IFACE $IF_RRQNET_PORT $IF_RRQNET_REMOTE fi - CHPID="$(cat /var/run/$NAME)" - [ -z "$RRQNET_RENICE" ] || [ -z "$CHPID" ] || \ - renice -n "$RRQNET_RENICE" "$CHPID" } #function -- 2.39.2