[Drbd-dev] [PATCH 3/6] drbd.ocf: Tune debug log output

Bart Van Assche bart.vanassche at sandisk.com
Tue Jun 14 13:56:13 CEST 2016


Log the name with which this script has been invoked together with
the script arguments. Make the environment variable filter more strict.

Signed-off-by: Bart Van Assche <bart.vanassche at sandisk.com>
---
 scripts/drbd.ocf | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/drbd.ocf b/scripts/drbd.ocf
index 44c4e44..84305db 100755
--- a/scripts/drbd.ocf
+++ b/scripts/drbd.ocf
@@ -135,8 +135,8 @@ then
 	# PS4='+[`date +%F\ %T.%3N`] '
 	exec 9>>"$DEBUG_LOG"
 	date >&9
-	echo "$*" >&9
-	env | grep OCF_ | sort >&9
+	echo "$0 $*" >&9
+	env | grep '^OCF_' | sort >&9
 else
 	exec 9>/dev/null
 fi
-- 
2.8.4



More information about the drbd-dev mailing list